MEncoder

„MEncoder is a free command line video decoding, encoding and filtering tool released under the GNU General Public License. It is a close sibling to MPlayer and can convert all the formats that MPlayer understands into a variety of compressed and uncompressed formats using different codecs.“

MEncoder. (2008, February 23). In Wikipedia, The Free Encyclopedia. Retrieved 18:57, April 5, 2008, from
http://en.wikipedia.org/w/index.php?title=MEncoder&oldid=193447614


My Blog List

Wednesday, May 21, 2008

Re: [MEncoder-users] number of yuv4mpeg frames does not match audio length.

On Wed, 21 May 2008, Maarten de Boer wrote:

> I am trying to convert a VOB file to h264+aac in an mp4 container (using
> x264, faac and MP4Box). I don't get the mp4 to be A/V sync (the
> material has some very obvious points). Investigating this problem, I
> found that the yuv4mpeg stream that I am using as input for x264 does
> not have the expected number of frames. As a reference, I look at the
> duration of the extracted audio:
>
> mplayer -vo null -ao pcm test.vob
>
> Duration : 00:00:11.168
>
> At my framerate of 29.97, this corresponds with 334.7 frames (not sure
> whether to round this up or truncate it)

Lossy encoders, by their nature, tend to pad at the end and, besides, the
audio isn't always (in fact, is rarely) exactly the same duration as the
video.

Lots of video suffers from sync problems, either because of how it's
encoded, or sloppy edits, or mixed hard/soft telecine, etc., etc., etc.
To get a usuable video stream, it's often necessary to examine the A/V
sync which, unfortunately, means muxing in audio. Try encoding with
-oac copy and see if you get dropped or duplicated frames.

> mplayer -harddup -noframedrop -vo yuv4mpeg -ao null test.vob
>
> 333 frames
>
> mencoder test.vob -vf-add harddup -vf-add =i420 -ovc raw -of rawvideo
> -nosound -o mencoder.420
>
> 333 frames

I've noticed that mencoder sometimes loses the last frame with some
coders, but raw output has been pretty reliable for me. A dropped last
frame wouldn't affect A/V sync at any rate.
_______________________________________________
MEncoder-users mailing list
MEncoder-users@mplayerhq.hu
https://lists.mplayerhq.hu/mailman/listinfo/mencoder-users

No comments:

PCBs

Links

Forex brokers, Forex online


Privacy Policy