[MPlayer-users] Transcoding 18 fps mpeg4 to VCD-compliant mpeg

RC rcooley at spamcop.net
Mon Nov 7 10:59:22 CET 2005


On Mon, 7 Nov 2005 11:05:20 +0800
Heimdall Midgard <heimdalle at gmail.com> wrote:

> Is is it even possible to convert an 18 fps mpeg4 video to a
> ~23.97 or ~29.97 fps VCD-compliant mpeg stream *without*
> losing audio-video sync?

It's a little bit of work to maintain sync, but it can always be done
with mencoder.

> As my system can't cope with recording at a full 29.97 fps, I'm forced
> to record at 18 fps.

I certainly wouldn't recomend that.  Try again at capturing at full
height, and full framerate with some of the changes below.

> :chanlist=us-cable:width=352:height=240:fps=18\

You really don't want to change the input framerate unless you
REALLY have to.  Try using 30000/1001 as the input, and use -ofps to
set the output framerate if you really have to.  As rich said, even
multiples of the real framerate are much better than random values.

> :amode=1:forcechan=2:audiorate=48000:alsa:adevice=hw.0 \
> -ovc lavc -oac lavc -lavcopts acodec=ac3:abitrate=96\

I imagine AC3 encoding is slower than MP2.

> :vcodec=mpeg4:keyint=0:vqscale=1 \

vqscale=1 without vqmin/vqmax also set, is probably working the same as
setting vqscale=2.  Also, I would recomend using the "nr=" option to
lower the output bitrate, reduce noise, and probably speed-up encoding
slightly.  I suggest starting with "nr=400" and trying other values from
there.

> -vf detc=dr=1,crop=336:224:8:8,pp=lb,denoise3d=8:6:12\

denoise3d is slow.  I would remove it and see if "nr=" (in lavcopts)
works well-enough for you instead.  Even if you still want to use
denoise3d, you're better-off doing it while re-encoding, rather than
during capture.

> The mpeg is recognized by VCDImager but when played back
> there's a huge audio-video desync of several seconds. What
> am I missing here?

Everything!!!

I haven't found a (DVD) player yet that would handle VCDs at 23.976fps
yet, nor 48khz audio.  It's also predictable that "format=mpeg1"
doesn't work.  You really, really need to read-up on VCD standards. The
MPlayer docs should give you much better guidance on what options to use
for VCDs.




More information about the MPlayer-users mailing list