[FFmpeg-devel] [PATCH] lavc/videotoolbox: validate vt context in the decoder callback

Zhao Zhili quinkblack at foxmail.com
Thu Dec 15 16:45:19 EET 2022


> -----Original Message-----
> From: ffmpeg-devel <ffmpeg-devel-bounces at ffmpeg.org> On Behalf Of Alessandro Di Nepi
> Sent: 2022年12月15日 22:16
> To: FFmpeg development discussions and patches <ffmpeg-devel at ffmpeg.org>
> Subject: Re: [FFmpeg-devel] [PATCH] lavc/videotoolbox: validate vt context in the decoder callback
> 
> Ping on this,
> Can I contribute somehow either to fix calling `av_videotoolbox_default_init` or at least update the docs?

Updating the docs doesn't work. This is a public API, it must be fixed properly: don't drop a feature, do what
it was supposed to do.

You can give a try, but I'm afraid it's a tricky regression.

> 
> Best Regards,
> Alessandro
> On 11 Dec 2022, 11:57 +0200, Alessandro Di Nepi <alessandro.dinepi at gmail.com>, wrote:
> > On 9 Dec 2022, 6:45 +0200, FFmpeg development discussions and patches <ffmpeg-devel at ffmpeg.org>, wrote:
> > > Did you call av_videotoolbox_default_init() or av_videotoolbox_default_init2()?
> > Actually yes, I call `av_videotoolbox_default_init(context);`
> > > I think that’s why avctx->internal->hwaccel_priv_data is NULL. That code path is broken.
> > > Does remove the call of av_videotoolbox_default_init()/av_videotoolbox_default_init2() works for you?
> > Definitively yes, if I remove the call to `av_videotoolbox_default_init` the context is fine.
> >
> > Thanks for sorting this out. I'd like to contribute and have this fixed or documented for other people.
> > What should be the desired behavior? Calling `av_videotoolbox_default_init` and having the context not NULL?
> > Or shall we remove the init at all?
> >
> > Best Regards
> _______________________________________________
> ffmpeg-devel mailing list
> ffmpeg-devel at ffmpeg.org
> https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
> 
> To unsubscribe, visit link above, or email
> ffmpeg-devel-request at ffmpeg.org with subject "unsubscribe".



More information about the ffmpeg-devel mailing list