[FFmpeg-devel] [PATCH 3/3] avcodec/mpeg12dec: Optimize reading mpeg2 intra escape codes

Michael Niedermayer michael at niedermayer.cc
Sat Oct 10 00:18:30 EEST 2020


On Thu, Oct 08, 2020 at 09:53:13PM +0200, Andreas Rheinhardt wrote:
> Said escape code is only six bits long, so that one has at least 25 - 6
> bits in the bitstream reader's cache after reading it; therefore the
> whole following 18 bits (containing the actual code) are already in the
> bitstream reader's cache, making it unnecessary to reload the cache.
> 
> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt at gmail.com>
> ---
>  libavcodec/mpeg12dec.c | 10 ++++------
>  1 file changed, 4 insertions(+), 6 deletions(-)

Interresting that this was not noticed before but
LGTM

thx

[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

During times of universal deceit, telling the truth becomes a
revolutionary act. -- George Orwell
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 195 bytes
Desc: not available
URL: <https://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20201009/665665f0/attachment.sig>


More information about the ffmpeg-devel mailing list