You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-08-10 06:10:52 +02:00
Fix get_bits_long to work with ALT_BITSTREAM_READER_LE.
Gives the same result as get_bits_long_le in vorbis.c instead of some wild big-/little-endian mixture. Originally committed as revision 6332 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
@@ -725,8 +725,13 @@ static inline void skip_bits1(GetBitContext *s){
|
|||||||
static inline unsigned int get_bits_long(GetBitContext *s, int n){
|
static inline unsigned int get_bits_long(GetBitContext *s, int n){
|
||||||
if(n<=17) return get_bits(s, n);
|
if(n<=17) return get_bits(s, n);
|
||||||
else{
|
else{
|
||||||
|
#ifdef ALT_BITSTREAM_READER_LE
|
||||||
|
int ret= get_bits(s, 16);
|
||||||
|
return ret | (get_bits(s, n-16) << 16);
|
||||||
|
#else
|
||||||
int ret= get_bits(s, 16) << (n-16);
|
int ret= get_bits(s, 16) << (n-16);
|
||||||
return ret | get_bits(s, n-16);
|
return ret | get_bits(s, n-16);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user