[libav-commits] libdav1d: fix build after a recent API break

James Almer git at libav.org
Thu Nov 15 15:28:46 CET 2018


Module: libav
Branch: master
Commit: 56f50183f38087e53c07cb670e5793f200d84d18

Author:    James Almer <jamrial at gmail.com>
Committer: James Almer <jamrial at gmail.com>
Date:      Wed Nov 14 22:04:35 2018 -0300

libdav1d: fix build after a recent API break

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

---

 libavcodec/libdav1d.c | 12 +++++++++---
 1 file changed, 9 insertions(+), 3 deletions(-)

diff --git a/libavcodec/libdav1d.c b/libavcodec/libdav1d.c
index ad4611f..3501c15 100644
--- a/libavcodec/libdav1d.c
+++ b/libavcodec/libdav1d.c
@@ -142,12 +142,18 @@ static int libdav1d_receive_frame(AVCodecContext *c, AVFrame *frame)
             }
 
             av_fifo_generic_write(dav1d->cache, &pkt, sizeof(pkt), libdav1d_fifo_write);
-        } else {
-            data = NULL;
         }
     }
 
-    res = dav1d_decode(dav1d->c, data, &p);
+    res = dav1d_send_data(dav1d->c, data);
+    if (res < 0) {
+        if (res == -EINVAL)
+            res = AVERROR_INVALIDDATA;
+        if (res != -EAGAIN)
+            return res;
+    }
+
+    res = dav1d_get_picture(dav1d->c, &p);
     if (res < 0) {
         if (res == -EINVAL)
             res = AVERROR_INVALIDDATA;



More information about the libav-commits mailing list