]> git.sesse.net Git - vlc/commitdiff
ogg demux: generate correct PTS for opus
authorRafaël Carré <funman@videolan.org>
Mon, 24 Jun 2013 04:50:23 +0000 (06:50 +0200)
committerRafaël Carré <funman@videolan.org>
Mon, 24 Jun 2013 04:50:39 +0000 (06:50 +0200)
Refs: #8295

modules/demux/ogg.c

index b572b44f11a93ca4ad182bc8ac73d2cac31182a4..d9312e8b5d399f155b5358f7ef7da95c2b066895 100644 (file)
@@ -948,8 +948,8 @@ static void Ogg_DecodePacket( demux_t *p_demux,
     if( i_pts == VLC_TS_INVALID ) i_pts = VLC_TS_0;
     else if( i_pts == -1 && i_interpolated_pts == VLC_TS_INVALID )
         i_pts = VLC_TS_0;
-    else if( i_pts == -1 && p_stream->fmt.i_cat == VIDEO_ES )
-        i_pts = i_interpolated_pts;
+    else if( i_pts == -1 && (p_stream->fmt.i_cat == VIDEO_ES || p_stream->fmt.i_codec == VLC_CODEC_OPUS) )
+        i_pts = i_interpolated_pts; /* FIXME : why is this incorrect for vorbis? */
     else if( i_pts == -1 ) i_pts = VLC_TS_INVALID;
 
     if( p_stream->fmt.i_cat == AUDIO_ES )