mirror of https://git.ffmpeg.org/ffmpeg.git
1000l to the ffsvq3 author, our default bitstream reader is only guranteed to be able to read 25bit at a time
Originally committed as revision 3237 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
parent
6258c7e674
commit
cceb990ef9
|
@ -80,7 +80,10 @@ static inline int svq3_get_ue_golomb(GetBitContext *gb){
|
|||
|
||||
return ff_interleaved_ue_golomb_vlc_code[buf];
|
||||
}else{
|
||||
buf|=1;
|
||||
LAST_SKIP_BITS(re, gb, 8);
|
||||
UPDATE_CACHE(re, gb);
|
||||
buf |= 1 | (GET_CACHE(re, gb) >> 8);
|
||||
|
||||
if((buf & 0xAAAAAAAA) == 0)
|
||||
return INVALID_VLC;
|
||||
|
||||
|
@ -88,7 +91,7 @@ static inline int svq3_get_ue_golomb(GetBitContext *gb){
|
|||
buf = (buf << 2) - ((buf << log) >> (log - 1)) + (buf >> 30);
|
||||
}
|
||||
|
||||
LAST_SKIP_BITS(re, gb, 63 - 2*log);
|
||||
LAST_SKIP_BITS(re, gb, 63 - 2*log - 8);
|
||||
CLOSE_READER(re, gb);
|
||||
|
||||
return ((buf << log) >> log) - 1;
|
||||
|
|
Loading…
Reference in New Issue