-oac copy and -of lavf shows audio data info wrong for flv videos.
When stream copying avc and aac with an flv container, the clip info of the audio data rate is showing completely wrong in Mplayer and MediaInfo. The command line: mencoder -ovc copy -oac copy -of lavf -lavfopts format=flv -fafmttag 0x706d infile.flv -o outfile.flv MEncoder Sherpya-SVN-r33883-4.2.5 (C) 2000-2011 MPlayer Team 163 audio & 369 video codecs success: format: 0 data: 0x0 - 0x5a2303 libavformat file format detected. [lavf] stream 0: video (h264), -vid 0 [lavf] stream 1: audio (aac), -aid 0, -alang und VIDEO: [H264] 640x360 24bpp 29.970 fps 685.6 kbps (83.7 kbyte/s) [V] filefmt:44 fourcc:0x34363248 size:640x360 fps:29.970 ftime:=0.0334 ** MUXER_LAVF ***************************************************************** REMEMBER: MEncoder's libavformat muxing is presently broken and can generate INCORRECT files in the presence of B-frames. Moreover, due to bugs MPlayer will play these INCORRECT files as if nothing were wrong! ******************************************************************************* OK, exit. videocodec: framecopy (640x360 24bpp fourcc=34363248) Forcing output audio format tag to 0x706d. audiocodec: framecopy (format=706d chans=2 rate=44100 bits=16 B/s=11999 sample-0) VIDEO CODEC ID: 28 AUDIO CODEC ID: 15002, TAG: 0 Writing header... [flv @ 0212b280] Codec for stream 0 does not use global headers but container format requires global headers [flv @ 0212b280] Codec for stream 1 does not use global headers but container format requires global headers Pos: 60.0s 1799f (99%) 0.00fps Trem: 0min 5mb A-V:0.001 [685:95]] Writing index... Video stream: 685.595 kbit/s (85699 B/s) size: 5144242 bytes 60.027 secs 1799 frames Audio stream: 95.995 kbit/s (11999 B/s) size: 726375 bytes 60.534 secs ------------------------------------------------------------------------ As you can see, the audio stream is 95 kbit/s. This is correct and is exactly the same as the original. However, playing with Mplayer - look at the audiodatarate - shows this: Clip info: duration: 61 width: 640 height: 360 videodatarate: 781 framerate: 30 videocodecid: 7 audiodatarate: 3 audiosamplerate: 44100 audiosamplesize: 16 stereo: true audiocodecid: 10 encoder: Lavf53.6.0 filesize: 5951333 Load subtitles in ./ ========================================================================== Opening audio decoder: [ffmpeg] FFmpeg/libavcodec audio decoders AUDIO: 44100 Hz, 2 ch, s16le, 3.4 kbit/0.24% (ratio: 421->176400) Selected audio codec: [ffaac] afm: ffmpeg (FFmpeg AAC (MPEG-2/MPEG-4 Audio)) ========================================================================== The audiodatarate is only showing 3 and 3.4 kbit as shown above. The program MediaInfo confirms this. Any ideas to correct this really appreciated.
I have found now that it is not only the stream copying command, but encoding an mp4 with AVC and AAC to a Flash Video flv with AVC and AAC resulted in extremely low audio bit rate. For example, a bit rate of 128 kbps wanted, resulted in only 3 kbps. Is there anything wrong with this command line please? mencoder inputfile.mp4 -o outputfile.flv -vf harddup -oac faac -faacopts mpeg=4:object=2:raw:br=128 -of lavf -lavfopts format=flv -ovc x264 -x264encopts level_idc=30:bframes=0:bitrate=768:global_header:subq=5:frameref=6:part itions=all:trellis=1:chroma_me:me=umh This command line below also resulted in 3 kbps for the audio, even though the original video has 128 kbps for the audio. mencoder -ovc copy -oac copy -of lavf -lavfopts format=flv -fafmttag 0x706d inputfile.flv -o outputfile.flv Is this the cause of it all? ========================================================================== ** MUXER_LAVF ***************************************************************** REMEMBER: MEncoder's libavformat muxing is presently broken and can generate INCORRECT files in the presence of B-frames. Moreover, due to bugs MPlayer will play these INCORRECT files as if nothing were wrong! ******************************************************************************* The "-x264encopts bframes=0" made no difference. It only seems to affect Flash Videos with AVC & AAC and the flv container. Is there any fix for this please?
participants (1)
-
Bill Crockett