Mercurial > libavcodec.hg
comparison vc9.c @ 2463:9baa47d8297b libavcodec
check norm6 vlc validity as there are some bit sequences which dont corespond to any codeword, the other vlc tables all seem to be huffman tables though
author | michael |
---|---|
date | Tue, 25 Jan 2005 01:29:10 +0000 |
parents | 5fd4de95731f |
children | ab390f13c7f5 |
comparison
equal
deleted
inserted
replaced
2462:5fd4de95731f | 2463:9baa47d8297b |
---|---|
850 tile_h= use_vertical_tile ? 3 : 2; | 850 tile_h= use_vertical_tile ? 3 : 2; |
851 | 851 |
852 for(y= bp->height%tile_h; y< bp->height; y+=tile_h){ | 852 for(y= bp->height%tile_h; y< bp->height; y+=tile_h){ |
853 for(x= bp->width%tile_w; x< bp->width; x+=tile_w){ | 853 for(x= bp->width%tile_w; x< bp->width; x+=tile_w){ |
854 code = get_vlc2(&v->gb, vc9_norm6_vlc.table, VC9_NORM6_VLC_BITS, 2); | 854 code = get_vlc2(&v->gb, vc9_norm6_vlc.table, VC9_NORM6_VLC_BITS, 2); |
855 if(code<0){ | |
856 av_log(v->avctx, AV_LOG_DEBUG, "inavlid NORM-6 VLC\n"); | |
857 return -1; | |
858 } | |
855 //FIXME following is a pure guess and probably wrong | 859 //FIXME following is a pure guess and probably wrong |
856 //FIXME A bitplane (0 | !0), so could the shifts be avoided ? | 860 //FIXME A bitplane (0 | !0), so could the shifts be avoided ? |
857 planep[x + 0*bp->stride]= (code>>0)&1; | 861 planep[x + 0*bp->stride]= (code>>0)&1; |
858 planep[x + 1 + 0*bp->stride]= (code>>1)&1; | 862 planep[x + 1 + 0*bp->stride]= (code>>1)&1; |
859 if(use_vertical_tile){ | 863 if(use_vertical_tile){ |