To prepare for using the cached bitstream reader, which only defines the inline functions rather than the macros, with CAVLC decoding.
Signed-off-by: Josh de Kock <j...@itanimul.li> --- libavcodec/h264_cavlc.c | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) diff --git a/libavcodec/h264_cavlc.c b/libavcodec/h264_cavlc.c index 6481992e58..c1ecaea1ba 100644 --- a/libavcodec/h264_cavlc.c +++ b/libavcodec/h264_cavlc.c @@ -414,19 +414,12 @@ av_cold void ff_h264_decode_init_vlc(void){ } static inline int get_level_prefix(GetBitContext *gb){ - unsigned int buf; int log; - OPEN_READER(re, gb); - UPDATE_CACHE(re, gb); - buf=GET_CACHE(re, gb); + log = 16 - av_log2_16bit(show_bits(gb, 16)); + skip_bits(gb, log); - log= 32 - av_log2(buf); - - LAST_SKIP_BITS(re, gb, log); - CLOSE_READER(re, gb); - - return log-1; + return log - 1; } /** -- 2.26.0 _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".