Message ID | 20211122205330.43546-8-rcombs@rcombs.me |
---|---|
State | New |
Headers | show |
Series | [FFmpeg-devel,01/16] ffmpeg: remove ffmpeg_videotoolbox | expand |
Context | Check | Description |
---|---|---|
andriy/make_x86 | success | Make finished |
andriy/make_fate_x86 | success | Make fate finished |
andriy/make_ppc | success | Make finished |
andriy/make_fate_ppc | success | Make fate finished |
On 11/22/2021 5:53 PM, rcombs wrote: > --- > libavcodec/h264_slice.c | 7 ++++--- > 1 file changed, 4 insertions(+), 3 deletions(-) > > diff --git a/libavcodec/h264_slice.c b/libavcodec/h264_slice.c > index 89ea16a57f..476a14d485 100644 > --- a/libavcodec/h264_slice.c > +++ b/libavcodec/h264_slice.c > @@ -798,6 +798,10 @@ static enum AVPixelFormat get_pixel_format(H264Context *h, int force_callback) > const enum AVPixelFormat *choices = pix_fmts; > int i; > > +#if CONFIG_H264_VIDEOTOOLBOX_HWACCEL > + *fmt++ = AV_PIX_FMT_VIDEOTOOLBOX; Does Videotoolbox support 9, 12 and 14 bit h264? Also, I'd prefer if you add one of these lines per bitdepth case instead. It's cleaner looking and proper. > +#endif > + > switch (h->ps.sps->bit_depth_luma) { > case 9: > if (CHROMA444(h)) { > @@ -872,9 +876,6 @@ static enum AVPixelFormat get_pixel_format(H264Context *h, int force_callback) > #endif > #if CONFIG_H264_VAAPI_HWACCEL > *fmt++ = AV_PIX_FMT_VAAPI; > -#endif > -#if CONFIG_H264_VIDEOTOOLBOX_HWACCEL > - *fmt++ = AV_PIX_FMT_VIDEOTOOLBOX; > #endif > if (h->avctx->codec->pix_fmts) > choices = h->avctx->codec->pix_fmts; >
diff --git a/libavcodec/h264_slice.c b/libavcodec/h264_slice.c index 89ea16a57f..476a14d485 100644 --- a/libavcodec/h264_slice.c +++ b/libavcodec/h264_slice.c @@ -798,6 +798,10 @@ static enum AVPixelFormat get_pixel_format(H264Context *h, int force_callback) const enum AVPixelFormat *choices = pix_fmts; int i; +#if CONFIG_H264_VIDEOTOOLBOX_HWACCEL + *fmt++ = AV_PIX_FMT_VIDEOTOOLBOX; +#endif + switch (h->ps.sps->bit_depth_luma) { case 9: if (CHROMA444(h)) { @@ -872,9 +876,6 @@ static enum AVPixelFormat get_pixel_format(H264Context *h, int force_callback) #endif #if CONFIG_H264_VAAPI_HWACCEL *fmt++ = AV_PIX_FMT_VAAPI; -#endif -#if CONFIG_H264_VIDEOTOOLBOX_HWACCEL - *fmt++ = AV_PIX_FMT_VIDEOTOOLBOX; #endif if (h->avctx->codec->pix_fmts) choices = h->avctx->codec->pix_fmts;