[MPlayer-users] trouble with he-aac in iphone videos

Sam Gendler sgendler at vid.me
Mon Jul 13 20:55:46 CEST 2009


I am using the macports version of mencoder (though I have the same results
when I build it myself), and I am getting an error when initializing the
audio decoder when trying to transocde a video from the iphone (or a flip
cam).  I know it isn't simply a problem of the codec not existing in the
build, as I can work with regular AAC streams without trouble.  If I build
ffmpeg against the exact same libfaad (I used --enable-faad-external when
the internal version failed to work, but with the same results), it
correctly decodes the audio of a file the mencoder cannot.  I am hoping that
there is some kind of command line parameter that I can pass through to
libfaad from mencoder which will cause it to correctly detect the stream
type and successfully initialize. If I use the following command:
mencoder input.mov -o output.mov -of lavf -oac lavc -lavcopts acodec=libfaac
-ovc x264
-x264encopts subq=5:8x8dct:frameref=2:bframes=3:b_pyramid:weight_b:bitrate=600000

It correctly transcodes the video, but it can't decode the audio.  I get the
following error messages

Opening audio decoder: [faad] AAC (MPEG2/4 Advanced Audio Coding)
FAAD: Failed to initialize the decoder!
ADecoder init failed :(
ADecoder init failed :(
Cannot find codec for audio format 0x6134706D.

If I explicitly specify the codec using -fafmttag 0x706D, the results are no
different.  If I add 0x6134706D as a format in the faad section of
codecs.conf, I get the same result.  I know that faad is capable of dealing
with this audio, since ffmpeg does it just fine (but it has issues with the
video - I can't win).  I don't see anything in all of my searches which
would suggest that there is some parameter I can specify which will get
passed through to libfaad, but I suspect that is what I need.

Also, -oac copy does not work, though that is actually what I would prefer,
since by transcoding, I'll be moving HE-AAC to AAC, and I'd really far
prefer to leave the HE-AAC intact.

Any advise would be greatly appreciated.  Basically, all I really want to do
is increase compression and resize an iphone video (I left the size change
filter out of the command above in order to simplify)

--sam


More information about the MPlayer-users mailing list