[FFmpeg-cvslog] r13850 - trunk/ffserver.c
bcoudurier
subversion
Sat Jun 21 05:43:16 CEST 2008
Author: bcoudurier
Date: Sat Jun 21 05:43:16 2008
New Revision: 13850
Log:
set default preload and max_delay for muxer to avoid mpeg ps muxer to spit many underflow errors, use ffmpeg default values
Modified:
trunk/ffserver.c
Modified: trunk/ffserver.c
==============================================================================
--- trunk/ffserver.c (original)
+++ trunk/ffserver.c Sat Jun 21 05:43:16 2008
@@ -2032,6 +2032,14 @@ static int http_prepare_data(HTTPContext
}
c->fmt_ctx.pb->is_streamed = 1;
+ /*
+ * HACK to avoid mpeg ps muxer to spit many underflow errors
+ * Default value from FFmpeg
+ * Try to set it use configuration option
+ */
+ c->fmt_ctx.preload = (int)(0.5*AV_TIME_BASE);
+ c->fmt_ctx.max_delay = (int)(0.7*AV_TIME_BASE);
+
av_set_parameters(&c->fmt_ctx, NULL);
if (av_write_header(&c->fmt_ctx) < 0) {
http_log("Error writing output header\n");
More information about the ffmpeg-cvslog
mailing list