[FFmpeg-devel] [PATCH] lavc/mjpegdec: hint next marker position in ff_mjpeg_find_marker

Matthieu Bouron matthieu.bouron at gmail.com
Fri Jan 27 10:47:18 EET 2017


On Fri, Jan 27, 2017 at 02:30:40AM +0100, Michael Niedermayer wrote:
> On Thu, Jan 26, 2017 at 05:47:51PM +0100, Matthieu Bouron wrote:
> > Speeds up next marker search when a SOS marker is found.
> > 
> > ff_mjpeg_find_marker goes from 54% to 30% under perf record ffmpeg -i
> > sample_2992x4000.jpg
> > ---
> >  libavcodec/mjpegdec.c | 31 +++++++++++++++++++++++++------
> >  libavcodec/mjpegdec.h |  2 +-
> >  libavcodec/mxpegdec.c |  5 +++--
> >  3 files changed, 29 insertions(+), 9 deletions(-)
> 
> this breaks decoding multiple jpeg files
> for example tickets//856/nint.jpg

New patch attached fixing the issue.

[...]
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-lavc-mjpegdec-hint-next-marker-position-in-ff_mjpeg_.patch
Type: text/x-diff
Size: 5952 bytes
Desc: not available
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20170127/dd6d6abc/attachment.patch>


More information about the ffmpeg-devel mailing list