shithub: dav1d

Download patch

ref: 69a0cbd9ee2d07bfcad5789ce23ca53b0aa83ef6
parent: 327b7de054ceda49529c038748644f9ebe617181
author: James Almer <jamrial@gmail.com>
date: Thu Nov 29 17:24:10 EST 2018

common: make Dav1dDataProps.duration signed

--- a/include/dav1d/common.h
+++ b/include/dav1d/common.h
@@ -53,7 +53,7 @@
  */
 typedef struct Dav1dDataProps {
     int64_t timestamp; ///< container timestamp of input data, default INT64_MIN
-    uint64_t duration; ///< container duration of input data, default -1
+    int64_t duration; ///< container duration of input data, default -1
     int64_t offset; ///< stream offset of input data, default INT64_MIN
     size_t size; ///< packet size, default Dav1dData.sz
 } Dav1dDataProps;
--- a/src/data.c
+++ b/src/data.c
@@ -65,7 +65,7 @@
     buf->data = ptr;
     buf->sz = buf->m.size = sz;
     buf->m.timestamp = buf->m.offset = INT64_MIN;
-    buf->m.duration = ~0ULL;
+    buf->m.duration = -1;
 
     return 0;
 }
--- a/src/picture.c
+++ b/src/picture.c
@@ -118,7 +118,7 @@
     p->p.w = w;
     p->p.h = h;
     p->m.timestamp = p->m.offset = INT64_MIN;
-    p->m.duration = ~0ULL;
+    p->m.duration = -1;
     p->p.layout = layout;
     p->p.bpc = bpc;
     int res = p_allocator->alloc_picture_callback(p, p_allocator->cookie);