[FFmpeg-cvslog] avcodec/options: Fix AVClassCategory of decoders with .receive_frame

Andreas Rheinhardt git at videolan.org
Tue Apr 5 21:37:45 EEST 2022


ffmpeg | branch: master | Andreas Rheinhardt <andreas.rheinhardt at outlook.com> | Thu Mar 31 00:19:37 2022 +0200| [1c3c29d07d7e0b7f5bec13cb0214f90e26604aee] | committer: Andreas Rheinhardt

avcodec/options: Fix AVClassCategory of decoders with .receive_frame

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt at outlook.com>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=1c3c29d07d7e0b7f5bec13cb0214f90e26604aee
---

 libavcodec/options.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavcodec/options.c b/libavcodec/options.c
index 91ab994994..2e05d29e1e 100644
--- a/libavcodec/options.c
+++ b/libavcodec/options.c
@@ -68,7 +68,7 @@ static const AVClass *codec_child_class_iterate(void **iter)
 static AVClassCategory get_category(void *ptr)
 {
     AVCodecContext* avctx = ptr;
-    if (avctx->codec && ffcodec(avctx->codec)->decode)
+    if (avctx->codec && av_codec_is_decoder(avctx->codec))
         return AV_CLASS_CATEGORY_DECODER;
     else
         return AV_CLASS_CATEGORY_ENCODER;



More information about the ffmpeg-cvslog mailing list