aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDawid Kozinski <d.kozinski@samsung.com>2024-04-18 12:53:08 +0200
committerJames Almer <jamrial@gmail.com>2024-05-08 21:14:56 -0300
commit0797651c12f643ea382d0ec09214670fd8d01b17 (patch)
tree2e06636eba94c1a9c83a6d57bb958b9f677ed2d4
parent214cbe29dc2c6aceb2167131137caa41cbd9f7b6 (diff)
downloadffmpeg-0797651c12f643ea382d0ec09214670fd8d01b17.tar.gz
avcodec/evc: Set the AV_FRAME_FLAG_KEY flag for a decoded frame when the decoded packet contains a keyframe
Signed-off-by: Dawid Kozinski <d.kozinski@samsung.com>
-rw-r--r--libavcodec/libxevd.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/libavcodec/libxevd.c b/libavcodec/libxevd.c
index 479d9be046..520fdab7d8 100644
--- a/libavcodec/libxevd.c
+++ b/libavcodec/libxevd.c
@@ -413,6 +413,10 @@ static int libxevd_receive_frame(AVCodecContext *avctx, AVFrame *frame)
return AVERROR(EAGAIN);
}
} else {
+ if (stat.stype == XEVD_ST_I) {
+ frame->pict_type = AV_PICTURE_TYPE_I;
+ frame->flags |= AV_FRAME_FLAG_KEY;
+ }
return libxevd_return_frame(avctx, frame, imgb, &pkt_au);
}
}