diff options
author | rcombs <rcombs@rcombs.me> | 2021-11-13 10:00:08 +0300 |
---|---|---|
committer | rcombs <rcombs@rcombs.me> | 2021-11-29 01:40:43 +0300 |
commit | b0c07f293883c5c37b5b1dbfabfca0d695250a60 (patch) | |
tree | 5de509c5baa9e04f302665c863924729978a9846 /libavcodec | |
parent | 79e51d6c0f0200c37d8d1f81bd55ea5f405c03fb (diff) |
lavc/videotoolbox: fix format computation
Use sw_pix_fmt instead of pix_fmt (consistent with other hwaccels)
Diffstat (limited to 'libavcodec')
-rw-r--r-- | libavcodec/videotoolbox.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/videotoolbox.c b/libavcodec/videotoolbox.c index bd6e769207..010f553e57 100644 --- a/libavcodec/videotoolbox.c +++ b/libavcodec/videotoolbox.c @@ -1059,7 +1059,7 @@ static int videotoolbox_uninit(AVCodecContext *avctx) } static enum AVPixelFormat videotoolbox_best_pixel_format(AVCodecContext *avctx) { - const AVPixFmtDescriptor *descriptor = av_pix_fmt_desc_get(avctx->pix_fmt); + const AVPixFmtDescriptor *descriptor = av_pix_fmt_desc_get(avctx->sw_pix_fmt); if (!descriptor) return AV_PIX_FMT_NV12; // same as av_videotoolbox_alloc_context() |