[MPlayer-users] REQ: Vdub compatibility for mencoder
Timothy B. Terriberry
tterribe at email.unc.edu
Mon Jul 28 06:00:08 CEST 2003
When appending two AVI files, Virtual Dub requires a fairly strict match
between the two stream headers. Currently, even with -oac copy -ovc
copy, mencoder produces headers completely incompatible with the
original file. This is unfortunate, as the error concealment features of
libavcodec are very useful for splicing out corrupt segments of a file,
re-encoding them with mencoder, and splicing them back in.
The first part of the problem (and the cause of -ova copy -ovc copy
failure), is that mencoder does not correctly copy the frame rate
parameters. Because of its internal use of floats, the frame rate in the
final AVI is _always_ different from the input, often by a significant
amount.
A second part of the problem is case sensitivity in the FOURCC codes.
For example vcodec=msmpeg4 produces a stream with FOURCC "div3" instead
of "DIV3". Vdub is not smart enough to match the two.
These are not the only problems, however. Even forcing the frame rates
to be the same by manually fixing up the header afterwards and forcing
the correct FOURCC with -ffourcc does not resolve the difference in
stream headers between what is produced by any of the standard Windows
codecs (DivX 3.11alpha, XviD, DivX 4/5), and the headers produced by
mencoder with libavcodec. I've had success in the past just copying over
random hex values from one header to the other, but do not remember
specific values/offsets from the last time I got this to work (months ago).
More information about the MPlayer-users
mailing list