[FFmpeg-cvslog] r22454 - in trunk: libavformat/oggdec.c tests/ref/seek/lavf.ogg.ref

conrad subversion
Thu Mar 11 08:17:30 CET 2010


Author: conrad
Date: Thu Mar 11 08:17:29 2010
New Revision: 22454

Log:
oggdec: Set data_offset to the right value

Otherwise it gets set automatically to a page midstream and prevents seeking
to the first page.

Modified:
   trunk/libavformat/oggdec.c
   trunk/tests/ref/seek/lavf.ogg.ref

Modified: trunk/libavformat/oggdec.c
==============================================================================
--- trunk/libavformat/oggdec.c	Thu Mar 11 08:17:24 2010	(r22453)
+++ trunk/libavformat/oggdec.c	Thu Mar 11 08:17:29 2010	(r22454)
@@ -382,6 +382,7 @@ ogg_packet (AVFormatContext * s, int *st
             os->segp = segp;
             os->psize = psize;
             ogg->headers = 1;
+            s->data_offset = os->sync_pos;
         }else{
             os->pstart += os->psize;
             os->psize = 0;

Modified: trunk/tests/ref/seek/lavf.ogg.ref
==============================================================================
--- trunk/tests/ref/seek/lavf.ogg.ref	Thu Mar 11 08:17:24 2010	(r22453)
+++ trunk/tests/ref/seek/lavf.ogg.ref	Thu Mar 11 08:17:29 2010	(r22454)
@@ -1,48 +1,48 @@
 ret: 0         st: 0 flags:1 dts: 0.000000 pts: 0.000000 pos:    125 size:  1364
 ret: 0         st:-1 flags:0  ts:-1.000000
-ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:   5768 size:  1390
+ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:   4353 size:  1382
 ret: 0         st:-1 flags:1  ts: 1.894167
 ret:-EIO
 ret: 0         st: 0 flags:0  ts: 0.788345
 ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:  11410 size:  1365
 ret: 0         st: 0 flags:1  ts:-0.317506
-ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:   2936 size:  1384
+ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:   1522 size:  1381
 ret: 0         st:-1 flags:0  ts: 2.576668
 ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:  12808 size:  1223
 ret: 0         st:-1 flags:1  ts: 1.470835
 ret:-EIO
 ret: 0         st: 0 flags:0  ts: 0.365011
-ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:   5768 size:  1390
+ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:   7191 size:  1370
 ret: 0         st: 0 flags:1  ts:-0.740839
-ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:   2936 size:  1384
+ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:   1522 size:  1381
 ret: 0         st:-1 flags:0  ts: 2.153336
 ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:  12808 size:  1223
 ret: 0         st:-1 flags:1  ts: 1.047503
 ret:-EIO
 ret: 0         st: 0 flags:0  ts:-0.058322
-ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:   5768 size:  1390
+ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:   4353 size:  1382
 ret: 0         st: 0 flags:1  ts: 2.835828
 ret:-EIO
 ret: 0         st:-1 flags:0  ts: 1.730004
 ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:  12808 size:  1223
 ret: 0         st:-1 flags:1  ts: 0.624171
-ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:   7191 size:  1370
-ret: 0         st: 0 flags:0  ts:-0.481655
 ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:   5768 size:  1390
+ret: 0         st: 0 flags:0  ts:-0.481655
+ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:   4353 size:  1382
 ret: 0         st: 0 flags:1  ts: 2.412494
 ret:-EIO
 ret: 0         st:-1 flags:0  ts: 1.306672
 ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:  12808 size:  1223
 ret: 0         st:-1 flags:1  ts: 0.200839
-ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:   2936 size:  1384
+ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:   1522 size:  1381
 ret: 0         st: 0 flags:0  ts:-0.904989
-ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:   5768 size:  1390
+ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:   4353 size:  1382
 ret: 0         st: 0 flags:1  ts: 1.989184
 ret:-EIO
 ret: 0         st:-1 flags:0  ts: 0.883340
 ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:  12808 size:  1223
 ret: 0         st:-1 flags:1  ts:-0.222493
-ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:   2936 size:  1384
+ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:   1522 size:  1381
 ret: 0         st: 0 flags:0  ts: 2.671678
 ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:  12808 size:  1223
 ret: 0         st: 0 flags:1  ts: 1.565850
@@ -50,4 +50,4 @@ ret:-EIO
 ret: 0         st:-1 flags:0  ts: 0.460008
 ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:   8594 size:  1381
 ret: 0         st:-1 flags:1  ts:-0.645825
-ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:   2936 size:  1384
+ret: 0         st: 0 flags:1 dts: NOPTS    pts: NOPTS    pos:   1522 size:  1381



More information about the ffmpeg-cvslog mailing list