[FFmpeg-cvslog] r11866 - trunk/libavformat/oggenc.c

bcoudurier subversion
Tue Feb 5 02:01:56 CET 2008


Author: bcoudurier
Date: Tue Feb  5 02:01:56 2008
New Revision: 11866

Log:
it seems ogg requires granule to be -1 on unfinished packets

Modified:
   trunk/libavformat/oggenc.c

Modified: trunk/libavformat/oggenc.c
==============================================================================
--- trunk/libavformat/oggenc.c	(original)
+++ trunk/libavformat/oggenc.c	Tue Feb  5 02:01:56 2008
@@ -51,7 +51,11 @@ static int ogg_write_page(AVFormatContex
     offset_t crc_offset;
     int page_segments, i;
 
-    size = FFMIN(size, 255*255);
+    if (size >= 255*255) {
+        granule = -1;
+        size = 255*255;
+    }
+
     page_segments = FFMIN((size/255)+!!size, 255);
 
     init_checksum(s->pb, ff_crc04C11DB7_update, 0);




More information about the ffmpeg-cvslog mailing list