[MPlayer-users] Re: [BUG] mencoder -oac lavc produces bad audio sync

Alexander Roalter alex at roalter.it
Wed Apr 4 09:22:01 CEST 2007


Rich Felker wrote:
> On Tue, Apr 03, 2007 at 04:18:40PM -0600, Joey Parrish wrote:
>> On 4/3/07, Joey Parrish <joey.parrish at gmail.com> wrote:
>>> ./mencoder $anything -ovc lavc -oac lavc -lavcopts
>>> acodec=mp3:abitrate=64:vcodec=mpeg4:vbitrate=200 -o noname.avi
>>> I also tried acodec=mp2 and acodec=ac3, same issues.
>>>
>>> Using mplayer noname.avi, video gets ahead of audio very fast.
>>> Using mplayer -nobps noname.avi, it plays correctly.
>>> Even with nobps option, audio restarts on any seek.
>>>
>>> If audio is encoded with mp3lame instead of lavc, the resulting file
>>> has no problems what-so-ever.
>> [snip]
>>> In the mean time, I will continue my svn
>>> search and try to identify the key change.
>> Aha!  I found it.  If I revert this change, the problem vanishes:
>> http://svn.mplayerhq.hu/mplayer/trunk/libmpcodecs/ae_lavc.c?r1=21787&r2=21789&view=patch
>> This is a December 29th commit by Michael.  If there are any devs
>> still listening on this list, please look into it.  I don't know
>> enough about the code in question to grok the problem or the fix
>> myself.  For now, I will patch my local copy.
> 
> Reverting this patch is not correct either. The old behavior had
> mencoder writing invalid 'CBR mode' AVI files where frames were split
> across AVI packets. Such AVI files are not valid but many codecs (such
> as mp3) can handle it anyway.
> 
> Michael was trying to fix this but I think he made a mistake...
> 
> Rich
This was the same I ran into last time, but first (with the aid of Nico) 
thought it was b/c of the B-frames options I used. But even without 
them, audio runs still ahead all the time with a restart at any seek... 
Now I'll wait a bit and watch what happens here, then I'll retry. :)





More information about the MPlayer-users mailing list