Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I have been trying to use FFmpeg utility to convert a avi file using DNxHD to mxf format. I am using "FFmpeg" with params as following:

 ffmpeg -i ccvt_box.avi -vcodec dnxhd -video_size 1920x1080 -r 24 -b:v 115m  ex.mxf        

The error it is giving :

ffmpeg version N-43737-g76c3fff Copyright (c) 2000-2012 the FFmpeg developers
  built on Aug 20 2012 18:50:42 with llvm-gcc 4.2.1 (LLVM build 2336.11.00)
  configuration: 
  libavutil      51. 70.100 / 51. 70.100
  libavcodec     54. 53.100 / 54. 53.100
  libavformat    54. 25.104 / 54. 25.104
  libavdevice    54.  2.100 / 54.  2.100
  libavfilter     3. 11.101 /  3. 11.101
  libswscale      2.  1.101 /  2.  1.101
  libswresample   0. 15.100 /  0. 15.100
Input #0, avi, from 'ccvt_box.avi':
  Duration: 00:00:10.00, start: 0.000000, bitrate: 691 kb/s
    Stream #0:0: Video: indeo5 (IV50 / 0x30355649), yuv410p, 340x344, 10 tbr, 10 tbn, 10 tbc
    Metadata:
      title           : bob.avi
[dnxhd @ 0x7fcd60818e00] video parameters incompatible with DNxHD
Output #0, mxf, to 'ex.mxf':
    Stream #0:0: Video: dnxhd, yuv422p, 340x344, q=2-1024, 90k tbn, 24 tbc
    Metadata:
      title           : bob.avi
Stream mapping:
  Stream #0:0 -> #0:0 (indeo5 -> dnxhd)
Error while opening encoder for output stream #0:0 - maybe incorrect parameters such as bit_rate, rate, width or height

UPDATE

➜  FFmpegTest  ffmpeg -i ccvt_box.avi -c:v dnxhd -s 1920x1080 -r 25 -b:v 115M ex.mxf
ffmpeg version N-43737-g76c3fff Copyright (c) 2000-2012 the FFmpeg developers
  built on Aug 20 2012 18:50:42 with llvm-gcc 4.2.1 (LLVM build 2336.11.00)
  configuration: 
  libavutil      51. 70.100 / 51. 70.100
  libavcodec     54. 53.100 / 54. 53.100
  libavformat    54. 25.104 / 54. 25.104
  libavdevice    54.  2.100 / 54.  2.100
  libavfilter     3. 11.101 /  3. 11.101
  libswscale      2.  1.101 /  2.  1.101
  libswresample   0. 15.100 /  0. 15.100
Input #0, avi, from 'ccvt_box.avi':
  Duration: 00:00:10.00, start: 0.000000, bitrate: 691 kb/s
    Stream #0:0: Video: indeo5 (IV50 / 0x30355649), yuv410p, 340x344, 10 tbr, 10 tbn, 10 tbc
    Metadata:
      title           : bob.avi
File 'ex.mxf' already exists. Overwrite ? [y/N] y
Output #0, mxf, to 'ex.mxf':
  Metadata:
    encoder         : Lavf54.25.104
    Stream #0:0: Video: dnxhd, yuv422p, 1920x1080, q=2-1024, 115000 kb/s, 25 tbn, 25 tbc
    Metadata:
      title           : bob.avi
Stream mapping:
  Stream #0:0 -> #0:0 (indeo5 -> dnxhd)
Press [q] to stop, [?] for help
frame=  249 fps= 59 q=1.0 Lsize=  147662kB time=00:00:09.96 bitrate=121450.5kbits/s dup=149 drop=0    
video:0kB audio:0kB subtitle:0 global headers:0kB muxing overhead inf%
Output file is empty, nothing was encoded (check -ss / -t / -frames parameters if used)

➜  FFmpegTest  ls -l ex.mxf 
-rw-r--r--  1 Prakash  staff  151205933 Sep  5 15:26 ex.mxf
share|improve this question
    
I see no error. Is this the complete ffmpeg console output? Also, option placement matters. You're applying all of your options to the input. Move it past -i input to apply your options to the output. –  LordNeckbeard Sep 2 '12 at 20:21
    
@LordNeckbeard Thanks for the information, I updated the question after making the modifications you told. –  Prakash Sep 3 '12 at 4:59
add comment

1 Answer 1

You need to use -s instead of -video_size (this is an option for some demuxers and the V4L2 input device), use 115M instead of 115m, and provide a valid frame rate with -r (25 [pal], 50, 30000/1001 [ntsc], 60000/1001):

ffmpeg -i ccvt_box.avi -c:v dnxhd -s 1920x1080 -r 25 -b:v 115M ex.mxf

Note that this example does not address any audio stream. Default audio encoder will be pcm_s16le.

In addition to FFmpeg there is also FFmbc which may provide additional DNxHD functionality.

share|improve this answer
    
I've found FFmpeg highly unreliable with DNxHD content and always use FFmbc for that. On this page there's a table with common DNxHD resolutions and bitrates (i.e. the values you put after -b:v). And yeah — FFmbc can't create MXF files either, just DVCPROHD or XDCAM. –  slhck Sep 4 '12 at 19:52
    
@LordNeckbeard Thanks for the help. But I have a requirement to convert to mxf format. How should I do then? –  Prakash Sep 4 '12 at 20:31
    
@Prakash Luckily, I have little experience with MXF, but I updated the answer so it will provide a DNxHD in MXF. Other encoder options are mpeg2video and dvvideo for video; pcm_s16le and pcm_s16le for audio. FFmbc will additionally allow xdcamhd422 video (examples). –  LordNeckbeard Sep 5 '12 at 3:29
    
+1 for the help so far. I have updated the question after what you told, there is still small problem. –  Prakash Sep 5 '12 at 10:11
    
Looks like a bug. I also get the same message, but the resulting file is playable in ffplay. I'll investigate and report it to the bug tracker. –  LordNeckbeard Sep 5 '12 at 19:09
show 1 more comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.