Michael Niedermayer <[EMAIL PROTECTED]> added the comment:

Does the patch below fix this for all your samples?
Index: libavformat/oggdec.c
===================================================================
--- libavformat/oggdec.c        (revision 13799)
+++ libavformat/oggdec.c        (working copy)
@@ -523,11 +523,25 @@
         return AVERROR(EIO);
     pkt->stream_index = idx;
     memcpy (pkt->data, os->buf + pstart, psize);
+    if (s->streams[idx]->codec->codec_id == CODEC_ID_VORBIS){
     if (os->lastgp != -1LL){                                 
         pkt->pts = ogg_gptopts (s, idx, os->lastgp);
         os->lastgp = -1;
     }
+    }else{
+        int segp= os->segp;
+        int nsegs=os->nsegs;
+        while (segp < nsegs){
+            if (os->segments[segp] < 255)
+                break;
+            segp++;
+        }

+        if (segp == nsegs && os->granule != -1LL){
+            pkt->pts = ogg_gptopts (s, idx, os->granule);
+        }
+    }
+
     pkt->flags = os->pflags;
                             
     return psize;

----------
substatus: open -> needs_more_info

______________________________________________________
FFmpeg issue tracker <[EMAIL PROTECTED]>
<https://roundup.mplayerhq.hu/roundup/ffmpeg/issue251>
______________________________________________________

Reply via email to