[FFmpeg-devel] [PATCH] Fix passlogfile naming when the user provide its own filename

Michael Niedermayer michaelni
Fri Dec 26 19:50:32 CET 2008


On Fri, Dec 26, 2008 at 02:45:38PM +0100, Stefano Sabatini wrote:
> On date Friday 2008-12-26 14:16:05 +0100, Michael Niedermayer encoded:
> > On Fri, Dec 26, 2008 at 02:11:52PM +0100, Stefano Sabatini wrote:
> > > On date Friday 2008-12-26 13:12:38 +0100, Stefano Sabatini encoded:
> > > > On date Friday 2008-12-26 13:02:36 +0100, Stefano Sabatini encoded:
> > > > > Hi all,
> > > > > 
> > > > > as spotted here:
> > > > > http://thread.gmane.org/6156dd8b0812252130w1d417b3dhd4008693154fdbe6 at mail.gmail.com
> > > > > 
> > > > > when the user set the passlog filename with -passlogfile FILENAME,
> > > > > ffmpeg adds an index and a .log suffix to the logfilename, so it will
> > > > > look like FILENAME-N.log, in contradiction with the documentation and
> > > > > causing problems if the order of the streams change in the second pass
> > > > > encoding.
> > > > > 
> > > > > First patch fixes it, the second one changes the macro
> > > > > DEFAULT_PASS_LOGFILENAME -> DEFAULT_PASS_LOGFILENAME_PREFIX, which is
> > > > > IMO more coherent with its meaning.
> > > > 
> > > > Doh, I pushed again the button too quickly, patch cannot work since
> > > > the passlogfile is set globally, when more than one encoding is done
> > > > then all the encoders will use the same filename, which is obviously
> > > > the wrong behaviour.
> > > > 
> > > > I think the cleanest solution would be to store the passlogfilename in
> > > > the encoder context, or maybe to use a map between encoders and
> > > > passlogfilenames.
> > > > 
> > > > Anyway the documentation should be changed in order to reflect the
> > > > current behaviour.
> > > 
> > > Check the patches below, regards.
> > 
> > ok
> 
> Doc patch applied, first patch for the N-pass log filename vars in ffmpeg
> reviewed, sorry for the noise.

ok

[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

> ... defining _GNU_SOURCE...
For the love of all that is holy, and some that is not, don't do that.
-- Luca & Mans
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20081226/4c7c8ce5/attachment.pgp>



More information about the ffmpeg-devel mailing list