Apparently flv only supports three audio sample rates, ffmpeg (and by extension media mover) isn't able to deal with files with files with nonstandard sample rates, causing files not to get processed to flv. I think adding a default sample rate, say of 22050, as a command line option to ffmpeg would fix this problem.

if you want the original files i used for this, check http://indyreader.org/node/125

bad (no sample rate):

john@bruno:~/Desktop$ ffmpeg -i Catonsville\ 40th\ anniversarsy\ action.mov -acodec mp3 test.flv
FFmpeg version SVN-rUNKNOWN, Copyright (c) 2000-2007 Fabrice Bellard, et al.
configuration: --enable-gpl --enable-pp --enable-swscaler --enable-pthreads --enable-libvorbis --enable-libtheora --enable-libogg --enable-libgsm --enable-dc1394 --disable-debug --enable-libmp3lame --enable-libfaadbin --enable-libfaad --enable-libfaac --enable-xvid --enable-x264 --enable-liba52 --enable-amr_nb --enable-amr_wb --enable-shared --prefix=/usr
libavutil version: 1d.49.3.0
libavcodec version: 1d.51.38.0
libavformat version: 1d.51.10.0
built on Dec 20 2007 21:22:28, gcc: 4.1.3 20070929 (prerelease) (Ubuntu 4.1.2-16ubuntu2)

Seems stream 1 codec frame rate differs from container frame rate: 1000.00 (1000/1) -> 29.97 (30000/1001)
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'Catonsville 40th anniversarsy action.mov':
Duration: 00:05:59.0, start: 0.000000, bitrate: 846 kb/s
Stream #0.0(eng): Audio: aac, 32000 Hz, stereo
Stream #0.1(eng): Video: mpeg4, yuv420p, 320x240, 29.97 fps(r)
Output #0, flv, to 'test.flv':
Stream #0.0: Video: flv, yuv420p, 320x240, q=2-31, 200 kb/s, 29.97 fps(c)
Stream #0.1: Audio: mp3, 32000 Hz, stereo, 64 kb/s
Stream mapping:
Stream #0.1 -> #0.0
Stream #0.0 -> #0.1
[mp3 @ 0x2af9e53a1810]flv doesnt support that sample rate, choose from (44100, 22050, 11025)
Could not write header for output file #0 (incorrect codec parameters ?)

good:
john@bruno:~/Desktop$ ffmpeg -i Catonsville\ 40th\ anniversarsy\ action.mov -ar 22050 -acodec mp3 test.flv
FFmpeg version SVN-rUNKNOWN, Copyright (c) 2000-2007 Fabrice Bellard, et al.
configuration: --enable-gpl --enable-pp --enable-swscaler --enable-pthreads --enable-libvorbis --enable-libtheora --enable-libogg --enable-libgsm --enable-dc1394 --disable-debug --enable-libmp3lame --enable-libfaadbin --enable-libfaad --enable-libfaac --enable-xvid --enable-x264 --enable-liba52 --enable-amr_nb --enable-amr_wb --enable-shared --prefix=/usr
libavutil version: 1d.49.3.0
libavcodec version: 1d.51.38.0
libavformat version: 1d.51.10.0
built on Dec 20 2007 21:22:28, gcc: 4.1.3 20070929 (prerelease) (Ubuntu 4.1.2-16ubuntu2)

Seems stream 1 codec frame rate differs from container frame rate: 1000.00 (1000/1) -> 29.97 (30000/1001)
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'Catonsville 40th anniversarsy action.mov':
Duration: 00:05:59.0, start: 0.000000, bitrate: 846 kb/s
Stream #0.0(eng): Audio: aac, 32000 Hz, stereo
Stream #0.1(eng): Video: mpeg4, yuv420p, 320x240, 29.97 fps(r)
Output #0, flv, to 'test.flv':
Stream #0.0: Video: flv, yuv420p, 320x240, q=2-31, 200 kb/s, 29.97 fps(c)
Stream #0.1: Audio: mp3, 22050 Hz, stereo, 64 kb/s
Stream mapping:
Stream #0.1 -> #0.0
Stream #0.0 -> #0.1
Press [q] to stop encoding
frame= 1639 q=23.4 Lsize= 2136kB time=54.7 bitrate= 319.9kbits/s
video:1649kB audio:428kB global headers:0kB muxing overhead 2.822302%

Comments

arthurf’s picture

Thank you very much for this. It's very helpful to get report backs on what does and what doesn't work. The problem here is that it's the FLV format that is the issue (since it requires mp3 @ 44100, 22050, 11025 bit rates). It's probably smart to just restrict to this and then have an "other" option with a note that this can break things.

I'll make the changes so that is reflected. Thanks!

mmcintee’s picture

This sounds exactly like the problem I'm having here:
http://drupal.org/node/262331
I thought it was a file size or video format issue, but it appears to be an audio khz issue. When an uploaded file has audio at 22.05Khz (22050) or 44.1khz (44100) it works.
Arthur, will you solve this by just updating the ffmpeg_wrapper module? Or is this something that we can adjust in the settings?

arthurf’s picture

I don't think this is the same issue. This will probably involve updates in both media mover and in ffmpeg wrapper as I want to build a database of "good formats" but those will need to be handled outside of ffmpeg wrapper