[FFmpeg-cvslog] avcodec/libdav1d: export level from the Sequence Header

James Almer git at videolan.org
Mon May 27 18:56:02 EEST 2019


ffmpeg | branch: master | James Almer <jamrial at gmail.com> | Mon May 27 12:47:33 2019 -0300| [0e07b767c86cc23c7a959e2b39fadd2088049f94] | committer: James Almer

avcodec/libdav1d: export level from the Sequence Header

Signed-off-by: James Almer <jamrial at gmail.com>

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

 libavcodec/libdav1d.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/libavcodec/libdav1d.c b/libavcodec/libdav1d.c
index 4fa3b0ae44..541d56dac8 100644
--- a/libavcodec/libdav1d.c
+++ b/libavcodec/libdav1d.c
@@ -223,6 +223,8 @@ static int libdav1d_receive_frame(AVCodecContext *c, AVFrame *frame)
     frame->linesize[2] = p->stride[1];
 
     c->profile = p->seq_hdr->profile;
+    c->level = ((p->seq_hdr->operating_points[0].major_level - 2) << 2)
+               | p->seq_hdr->operating_points[0].minor_level;
     frame->format = c->pix_fmt = pix_fmt[p->p.layout][p->seq_hdr->hbd];
     frame->width = p->p.w;
     frame->height = p->p.h;



More information about the ffmpeg-cvslog mailing list