[MEncoder-users] mencoder audio is faster than video

James Hastings-Trew jimht at shaw.ca
Wed Nov 26 00:56:13 CET 2008


Emmanuel Guarda wrote:
> i'm triing to encode tv programs with a bt878 based card that works
> prefectly with tvtime.
> te code that use to encode is:
>
> *mencoder tv:// -tv
> forceaudio:alsa:driver=v4l2:input=0:norm=pal-nc:chanlist=us-cable:channel=$CHAN:width=640:height=480
> -ovc lavc -lavcopts vcodec=mpeg4:vbitrate=3000 -ofps 25 -oac mp3lame
> -lavcopts acodec=mp3:abitrate=128 -srate 48000 -noskip -mc 0 -vf
> scale=640:480,pp=hb/vb/dr/al/lb -endpos $DURATION -o "$FNAME"_`date
> +%m%d`.avi -quiet*
> the image and audio hears perfect, but when i record a long time, the audio
> is before the video.
>   
Have you tried putting harddup at the end of your filter chain?

-vf scale=640:480,pp=hb/vb/dr/al/lb,harddup

And remove the -noskip -mc 0. Mencoder maintains AV synch by adding or removing frames. Putting -noskip -mc 0 in there effectively disables this. Also, try putting -fps 25 in there as well. Just some suggestions off the top of my head.





More information about the MEncoder-users mailing list