[FFmpeg-devel] [PATCH] lavc/pngdec: always create a copy for APNG_DISPOSE_OP_BACKGROUND

Michael Niedermayer michael at niedermayer.cc
Thu Apr 8 22:59:11 EEST 2021


On Thu, Apr 08, 2021 at 05:34:30PM +0200, Michael Niedermayer wrote:
> On Thu, Apr 08, 2021 at 10:46:54AM +0200, Anton Khirnov wrote:
> > Calling av_frame_make_writable() from decoders is tricky, especially
> > when frame threading is used. It is much simpler and safer to just make
> > a private copy of the frame.
> > This is not expected to have a major performance impact, since
> > APNG_DISPOSE_OP_BACKGROUND is not used often and
> > av_frame_make_writable() would typically make a copy anyway.
> > 
> > Found-by: James Almer <jamrial at gmail.com>
> > ---
> >  libavcodec/pngdec.c | 18 +++++++++++-------
> >  1 file changed, 11 insertions(+), 7 deletions(-)
> 
> LGTM

i will apply and backport this if it has not been applied when i make the
4.4 release

thx

[...]

-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Frequently ignored answer#1 FFmpeg bugs should be sent to our bugtracker. User
questions about the command line tools should be sent to the ffmpeg-user ML.
And questions about how to use libav* should be sent to the libav-user ML.
-------------- 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/20210408/4906d583/attachment.sig>


More information about the ffmpeg-devel mailing list