[MEncoder-users] handling stupid mpeg-4 decoder (ffmpeg works but mencoder doesn't)
Se Heon Ryu
blankblackwhite at gmail.com
Sun Oct 19 06:39:19 CEST 2008
my mobile has fastidious mpeg-4 decoder.
mencoder -mc 0 -of lavf -oac lavc -ovc lavc -lavfopts format=mp4
-lavcopts threads=2:acodec=libfaac:abitrate=256:aglobal=1:vcodec=mpeg4
:vbitrate=768:vglobal=1:vqscale=2:mbd=2:trell:v4mv -af lavcresample=44100
-vf expand=aspect=5/3,scale=400:240,harddup blah -o blah
makes compatible file but decoder in phone lacks deblocker and makes
unbearable block artifacts
besides even default key_int makes crazy p frame artifacts.
so I switched to xvid but couldn't get working files on mencoder.
tried changing every xvidencopts and found that only
ffmpeg -vcodec libxvid -s 400x240 -b 768000 -acodec libfaac -ac 2 -ar
44100 -ab 256000 -f mp4 -i blah blah
works on mobile and it gives resonable quality.
below is some detail about working xvid file. (though I can't maintain
aspect ratio in ffmpeg yet)
Format : MPEG-4
Format profile : Base Media
Codec ID : isom
File size : 3.41 MiB
Duration : 20s 20ms
Overall bit rate : 1 429 Kbps
Encoded date : UTC 1970-01-01 00:00:00
Tagged date : UTC 1970-01-01 00:00:00
Video #1
Format : MPEG-4 Visual
Format profile : Simple at L3
Format settings, BVOP : No
Format settings, QPel : No
Format settings, GMC : No warppoints
Format settings, Matrix : Default
Codec ID : 20
Duration : 20s 20ms
Bit rate mode : Variable
Bit rate : 1 272 Kbps
Width : 400 pixels
Height : 240 pixels
Display aspect ratio : 16/9
Frame rate mode : Constant
Frame rate : 29.970 fps
Resolution : 24 bits
Colorimetry : 4:2:0
Scan type : Progressive
Bits/(Pixel*Frame) : 0.442
Stream size : 3.04 MiB (89%)
Writing library : XviD 1.1.2 (UTC 2006-11-01)
Encoded date : UTC 1970-01-01 00:00:00
Tagged date : UTC 1970-01-01 00:00:00
Audio #2
Format : AAC
Format/Info : Advanced Audio Codec
Format version : Version 4
Format profile : LC
Format settings, SBR : No
Codec ID : 40
Duration : 19s 945ms
Bit rate mode : Variable
Bit rate : 152 Kbps
Channel(s) : 2 channels
Channel positions : L R
Sampling rate : 44.1 KHz
Resolution : 16 bits
Stream size : 371 KiB (11%)
Encoded date : UTC 1970-01-01 00:00:00
Tagged date : UTC 1970-01-01 00:00:00
knowing which profile to use and which library it should use I tried
mencoder -mc 0 -of lavf -oac lavc -ovc xvid -lavfopts format=mp4
-lavcopts acodec=libfaac:abitrate=256:aglobal=1 -xvidencopts bitrate=768
:max_bframes=0 -af lavcresample=44100 -vf
expand=aspect=5/3,scale=400:240,harddup blah -o blah
and it gives same detail about file. but not playable on mobile :-(
Spending 8 hours 0am~4am*2days I'm getting exhausted.
I just need precise mencoder command which does what
ffmpeg -vcodec libxvid -s 400x240 -b 768000 -acodec libfaac -ac 2 -ar
44100 -ab 256000 -f mp4 -i blah blah
does.
Sorry for exhaustive post...
Any help would be appreciated.
More information about the MEncoder-users
mailing list