[MEncoder-users] A/V sync problem when encoding TS stream into MPEG4
Robert Nichols
rnicholsNOSPAM at comcast.net
Sun May 4 03:00:58 CEST 2008
Jiri Hofman wrote:
> Hello
>
> I am experiencing a mencoder problem which appeared during development.
> I am not sure if this is a duplicate report, however, I will describe it.
>
> MEncoder 1.0pre8-4.1.2 encodes TS stream (DVB stream stored by Kaffeine,
> I can provide a sample if neccessary) prefectly -- A/V sync is just great.
>
> After I upgraded to latest version or SVN, A/V sync is lost. When you try to
> seek in generated AVI, video seeks but sound plays from beginning of file.
>
> Do I do anything wrong?
That's the same problem I reported on Apr 29 "Bad timestamps from lavc audio
encodings in AVI container"
http://lists.mplayerhq.hu/pipermail/mencoder-users/2008-April/008663.html
Digging back through the mailing list archives, the best advice I've found
is, "Don't use libavcodec for audio when making AVI files." The problem
has been around for more than a year now. Here's a link to a summary that
includes links to previous threads on this problem:
http://lists.mplayerhq.hu/pipermail/mencoder-users/2007-December/007644.html
FWIW, I've found that the suggestion there to use the lavf muxer to create
the AVI file does not work any better.
Since you want ac3 audio, it appears you have no choice but to use the
lavc audio codec. Using an MPEG container in place of AVI (-of mpeg)
avoids the problem. If you really want an AVI file, you can then convert
the MPEG file to AVI using "-oac copy -ovc copy". In the tests I've tried,
the resulting AVI file plays properly.
--
Bob Nichols "NOSPAM" is really part of my email address.
Do NOT delete it.
More information about the MEncoder-users
mailing list