Opened 8 years ago

Last modified 8 years ago

#1900 new defect

Choppy video encoding to mpeg2 from h264 (mp4 container)

Reported by: mmbossoni@… Owned by: reimar
Priority: normal Component: ve
Version: unspecified Severity: major
Keywords: Cc:
Blocked By: Blocking:
Reproduced by developer: Analyzed by developer:


I'm using PS3 media server that uses mencoder
mencoder 33159 (from archlinux repositories)

With one of the movies it is choppy and slow.

Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'video1.mp4':


major_brand : isom
minor_version : 1
compatible_brands: isomavc1
creation_time : 2011-02-19 19:16:00
encoder : Yamb

Duration: 00:23:57.08, start: 0.021333, bitrate: 3256 kb/s

Stream #0.0(und): Video: h264 (Main), yuv420p, 1280x720 [PAR 1:1 DAR 16:9], 3006 kb/s, 23.98 fps, 23.98 tbr, 24k tbn, 47.95 tbc

creation_time : 2011-02-19 19:16:00

Stream #0.1(und): Audio: aac, 48000 Hz, stereo, s16, 245 kb/s

creation_time : 2011-02-19 19:16:18

With the second one, everything is fine (avi container)

Input #0, avi, from 'video2.avi':


encoder : VirtualDubMod? (build 2540/release)

Duration: 01:35:15.66, start: 0.000000, bitrate: 3849 kb/s

Stream #0.0: Video: mpeg4, yuv420p, 1280x528 [PAR 1:1 DAR 80:33], 23.98 tbr, 23.98 tbn, 23.98 tbc
Stream #0.1: Audio: ac3, 48000 Hz, 5.1, s16, 640 kb/s

the executed line for encoding is

mkfifo --mode=777 /tmp/javaps3media/mencoder1301695142450

mencoder -ss 0 -quiet /home/marcelo/dados/temp/video1.mp4 -quiet -quiet -oac lavc -of mpeg -quiet -quiet -mpegopts format=mpeg2:muxrate=500000:vbuf_size=1194:abuf_size=
64 -ovc lavc -channels 2 -lavdopts debug=0:threads=4 -lavcopts autoaspect=1:vcodec=mpeg2video:acodec=ac3:abitrate=256:threads=4:keyint=1:vqscale=1:vqmin=2:vrc_maxrate=30000:vrc_buf_size=1835 -ass-color ffffff00 -ass-border-color 00000000 -ass-font-scale 1.0 -ass-force-style FontName?=Arial,Outline=1,Shadow=1,MarginV=10 -quiet -quiet -subdelay 20000 -quiet -quiet -ofps 24000/1001 -quiet -quiet -mc 0.1 -quiet -af lavcresample=48000 -srate 48000 -o /tmp/javaps3media/mencoder1301695142450

Any idea waht is going on?

Change History (2)

comment:1 Changed 8 years ago by mmbossoni@…

Forgot to mention that I tried to convert the aac audio of video1.mp4 to ac3 with ffmpeg using another container (mkv). Doing this conversion video worked OK, but audio was slow and out of sync.

comment:2 Changed 8 years ago by mmbossoni@…

I'm glad to tell that I tracked down the "tainted" codec. The problem is use the acodec=ac3 in the -lavcopts. If I use the libmp3lame everything works really fine.

Now I just don't know why...

Note: See TracTickets for help on using tickets.