[FFmpeg-devel] [PATCH] Initializing pack_header_freq
Diep Ho
DHo
Mon Sep 1 15:40:41 CEST 2008
I propose to use mux_rate to set the value of pack_header_freq. This
should provide a better value when in VBR mode. Moreover, it is
configurable through mux_rate.
Rgds,
DHO
===================================================================
--- libavformat/mpegenc.c (revision 15138)
+++ libavformat/mpegenc.c (working copy)
@@ -451,7 +451,7 @@
s->pack_header_freq = 1;
else
/* every 2 seconds */
- s->pack_header_freq = 2 * bitrate / s->packet_size / 8;
+ s->pack_header_freq = 2 * 50 * s->mux_rate / s->packet_size;
/* the above seems to make pack_header_freq zero sometimes */
if (s->pack_header_freq == 0)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: packheaderfreq.patch
Type: application/octet-stream
Size: 515 bytes
Desc: packheaderfreq.patch
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20080901/8554f340/attachment.obj>
More information about the ffmpeg-devel
mailing list