diff oggdec.h @ 5514:52c7b29eca31 libavformat

oggdec: Set dts when known
author conrad
date Mon, 11 Jan 2010 05:51:09 +0000
parents 60671fac35ad
children 37e2c3e635b3
line wrap: on
line diff
--- a/oggdec.h	Mon Jan 11 00:31:55 2010 +0000
+++ b/oggdec.h	Mon Jan 11 05:51:09 2010 +0000
@@ -40,7 +40,12 @@
      */
     int (*header)(AVFormatContext *, int);
     int (*packet)(AVFormatContext *, int);
-    uint64_t (*gptopts)(AVFormatContext *, int, uint64_t);
+    /**
+     * Translate a granule into a timestamp.
+     * Will set dts if non-null and known.
+     * @return pts
+     */
+    uint64_t (*gptopts)(AVFormatContext *, int, uint64_t, int64_t *dts);
     /**
      * 1 if granule is the start time of the associated packet.
      * 0 if granule is the end time of the associated packet.
@@ -60,6 +65,7 @@
     uint32_t seq;
     uint64_t granule;
     int64_t lastpts;
+    int64_t lastdts;
     int flags;
     const struct ogg_codec *codec;
     int header;