[MEncoder-users] Howto fix audio delay

The Wanderer inverseparadox at comcast.net
Mon Jul 4 16:07:58 CEST 2005


Nico Sabbi wrote:

> Florian Schulze wrote:
> 
>> Hi!
>> 
>> I encoded videos with xvid (1.1beta from thursday) and mp3 with vbr
>> and the sound is played to late, I can adjust it with a audio
>> delay of -500ms. Now I want to make that permanent in the avi. How
>> can I do that, VirtualDub chokes on the VBR.
> 
> mencoder -audio-delay ...

According to the man page, that doesn't work with negative delay values,
meaning that while you can use it to correct for audio which is played
too early it won't help with audio which is played too late.

I don't personally know of any reason why it would not be theoretically
possible to simply pad the beginning of either the audio stream (in the
case of "audio played too early") or the video stream (in the case of
"audio played too late") with 'blank' frames during the encoding stage,
such that in the former case no sound would be played and in the latter
case no video would be output, to correct for the mis-synchronization,
but since no one has attempted to implement such a seemingly obvious
thing I suppose there might be a technical obstacle I'm not aware of.

The more severe problem comes when the degree of desync changes over the
course of the video, and I know of no way to automatically correct that
- either in encoding or in playback - other than either careful,
painstaking stream editing 'by hand' or re-encoding from the original,
in-sync source. Unfortunately most of the files I have which are out of
sync are of this latter nature.

-- 
       The Wanderer

Warning: Simply because I argue an issue does not mean I agree with any
side of it.

A government exists to serve its citizens, not to control them.




More information about the MEncoder-users mailing list