#8761 closed defect (invalid)

DNxHD encoder does not accept 80, 90, 100, 110M bitrates, although the error message indicates it should

Reported by: Dan Ionescu Owned by:
Priority: normal Component: avcodec
Version: unspecified Keywords:
Cc: Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no

Description

Summary of the bug:
I can encode 1440x1080 subsampled interlaced dnxhd encoded in MXF container at 120M bitrate, but not at 80M, 90M, 100M or 110M, using the bellow command line.
According to the error message displayed by the ffmpeg binary these bitrates should be ok, but they are not accepted in fact.

[dnxhd @ 0000015bb4b93e40] Frame size: 1440x1080i; bitrate: 80Mbps; pixel format: yuv422p
[dnxhd @ 0000015bb4b93e40] Frame size: 1440x1080i; bitrate: 90Mbps; pixel format: yuv422p
[dnxhd @ 0000015bb4b93e40] Frame size: 1440x1080i; bitrate: 100Mbps; pixel format: yuv422p
[dnxhd @ 0000015bb4b93e40] Frame size: 1440x1080i; bitrate: 110Mbps; pixel format: yuv422p
[dnxhd @ 0000015bb4b75840] ff_frame_thread_encoder_init failed
Error initializing output stream 0:0 -- Error while opening encoder for output stream #0:0 - maybe incorrect parameters such as bit_rate, rate, width or height

I also tried with the latest release of ffmpeg and with the latest nightly build, both compiled on linux, obtaining the same unwanted result.

How to reproduce:

% ffmpeg -i prores.mov -s 1440x1080 -r 25 -flags +ilme+ildct -c:v dnxhd -b:v 80M -pix_fmt yuv422p -an -f mxf_opatom output.mxf
ffmpeg version 4.2.1
built on windows 10

Change History (6)

comment:1 by Carl Eugen Hoyos, 17 months ago

Version: 4.2unspecified

Please test current FFmpeg git head and provide the command line you tested together with complete, uncut console output to make this a valid ticket.

comment:2 by Dan Ionescu, 17 months ago

Version: unspecified4.2

Sure thing. I'll do it right now. I expect in 30 min to provide the information requsted.
Thank you.

comment:3 by Dan Ionescu, 17 months ago

Version: 4.2unspecified

comment:4 by Dan Ionescu, 17 months ago

Hust finished testing with the lates master from git. The result is the same.
The comand is as follows:

ffmpeg -i prores.mov -s 1440x1080 -r 25 -flags +ilme+ildct -c:v dnxhd -b:v 80M -pix_fmt yuv422p -an -f mxf_opatom output.mxf

Here is the output from the console:

$ ffmpeg -i prores.mov -s 1440x1080 -r 25 -flags +ilme+ildct -c:v dnxhd -b:v 80M -pix_fmt yuv422p -an -f mxf_opatom output.mxf
ffmpeg version N-98340-g4cfcfb3677 Copyright (c) 2000-2020 the FFmpeg developers
  built with gcc 8 (Debian 8.3.0-6)
  configuration:
  libavutil      56. 55.100 / 56. 55.100
  libavcodec     58. 93.100 / 58. 93.100
  libavformat    58. 47.100 / 58. 47.100
  libavdevice    58. 11.100 / 58. 11.100
  libavfilter     7. 86.100 /  7. 86.100
  libswscale      5.  8.100 /  5.  8.100
  libswresample   3.  8.100 /  3.  8.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'prores.mov':
  Metadata:
    major_brand     : qt
    minor_version   : 537199360
    compatible_brands: qt
    creation_time   : 2017-08-07T17:45:32.000000Z
  Duration: 00:00:08.04, start: 0.000000, bitrate: 170463 kb/s
    Stream #0:0(eng): Video: prores (HQ) (apch / 0x68637061), yuv422p10le(tv, progressive), 1920x1080, 168886 kb/s, SAR 1:1 DAR 16:9, 25 fps, 25 tbr, 25 tbn, 25 tbc (default)
    Metadata:
      creation_time   : 2017-08-07T17:45:32.000000Z
      handler_name    : Apple Video Media Handler
      encoder         : Miraizon ProRes 422 (HQ)
      timecode        : 00:00:00:00
    Stream #0:1(eng): Audio: pcm_s16le (sowt / 0x74776F73), 48000 Hz, stereo, s16, 1536 kb/s (default)
    Metadata:
      creation_time   : 2017-08-07T17:45:32.000000Z
      handler_name    : Apple Sound Media Handler
      timecode        : 00:00:00:00
    Stream #0:2(eng): Data: none (tmcd / 0x64636D74), 0 kb/s (default)
    Metadata:
      creation_time   : 2017-08-07T17:50:19.000000Z
      handler_name    : Time Code Media Handler
      timecode        : 00:00:00:00
Stream mapping:
  Stream #0:0 -> #0:0 (prores (native) -> dnxhd (native))
Press [q] to stop, [?] for help
[dnxhd @ 0x556c29bb5540] Profile selected is experimental
[dnxhd @ 0x556c29bb5540] video parameters incompatible with DNxHD. Valid DNxHD profiles:
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080p; bitrate: 175Mbps; pixel format: yuv422p10
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080p; bitrate: 185Mbps; pixel format: yuv422p10
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080p; bitrate: 365Mbps; pixel format: yuv422p10
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080p; bitrate: 440Mbps; pixel format: yuv422p10
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080p; bitrate: 115Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080p; bitrate: 120Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080p; bitrate: 145Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080p; bitrate: 240Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080p; bitrate: 290Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080p; bitrate: 175Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080p; bitrate: 185Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080p; bitrate: 220Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080p; bitrate: 365Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080p; bitrate: 440Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080i; bitrate: 185Mbps; pixel format: yuv422p10
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080i; bitrate: 220Mbps; pixel format: yuv422p10
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080i; bitrate: 120Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080i; bitrate: 145Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080i; bitrate: 185Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080i; bitrate: 220Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1440x1080i; bitrate: 120Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1440x1080i; bitrate: 145Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1280x720p; bitrate: 90Mbps; pixel format: yuv422p10
[dnxhd @ 0x556c29bb5540] Frame size: 1280x720p; bitrate: 180Mbps; pixel format: yuv422p10
[dnxhd @ 0x556c29bb5540] Frame size: 1280x720p; bitrate: 220Mbps; pixel format: yuv422p10
[dnxhd @ 0x556c29bb5540] Frame size: 1280x720p; bitrate: 90Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1280x720p; bitrate: 110Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1280x720p; bitrate: 180Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1280x720p; bitrate: 220Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1280x720p; bitrate: 60Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1280x720p; bitrate: 75Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1280x720p; bitrate: 120Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1280x720p; bitrate: 145Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080p; bitrate: 36Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080p; bitrate: 45Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080p; bitrate: 75Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080p; bitrate: 90Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080p; bitrate: 350Mbps; pixel format: yuv444p10, gbrp10
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080p; bitrate: 390Mbps; pixel format: yuv444p10, gbrp10
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080p; bitrate: 440Mbps; pixel format: yuv444p10, gbrp10
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080p; bitrate: 730Mbps; pixel format: yuv444p10, gbrp10
[dnxhd @ 0x556c29bb5540] Frame size: 1920x1080p; bitrate: 880Mbps; pixel format: yuv444p10, gbrp10
[dnxhd @ 0x556c29bb5540] Frame size: 960x720p; bitrate: 42Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 960x720p; bitrate: 60Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 960x720p; bitrate: 75Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 960x720p; bitrate: 115Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1440x1080p; bitrate: 63Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1440x1080p; bitrate: 84Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1440x1080p; bitrate: 100Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1440x1080p; bitrate: 110Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1440x1080i; bitrate: 80Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1440x1080i; bitrate: 90Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1440x1080i; bitrate: 100Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29bb5540] Frame size: 1440x1080i; bitrate: 110Mbps; pixel format: yuv422p
[dnxhd @ 0x556c29112600] ff_frame_thread_encoder_init failed
Error initializing output stream 0:0 -- Error while opening encoder for output stream #0:0 - maybe incorrect parameters such as bit_rate, rate, width or height

in reply to:  4 comment:5 by Carl Eugen Hoyos, 17 months ago

Replying to dvision:
(I am not a native speaker, do you think there is a better word than together?)

[dnxhd @ 0x556c29bb5540] Profile selected is experimental

Did you test with strict -2?

comment:6 by Dan Ionescu, 17 months ago

Resolution: invalid
Status: newclosed

My bad and my apologies, along with a big thank you. I tried with strict -1, but I didn't know there is also a -2 option.
Regards and thank you again.

Note: See TracTickets for help on using tickets.