• Gaullier Nicolas's avatar
    avformat/mxfenc: set/force channelcount in MXF D-10 · 3eae34d5
    Gaullier Nicolas authored
    There are interoperability issues with D-10 related to the channelcount property in the generic sound essence descriptor.
    
    On one side, SMPTE 386M requires channel count to be 4 or 8, other values being prohibited.
    The most widespread value is 8, which seems straightforward as it is the actual size of the allocated structure/disk space.
    At the end, it appears that some vendors or workflows do require this descriptor to be 8, and otherwise just "fail".
    
    On the other side, at least AVID and ffmpeg do write/set the channel count to the exact number of channels really "used",
    usually 2 or 4, or any other value. And on the decoding side, ffmpeg (for example) make use of the channel count for probing
    and only expose this limited number of audio streams
    (which make sense but has strong impact on ffmpeg command line usage, output, and downstream workflow).
    
    At the end, I find it pretty usefull to simply give ffmpeg the ability to force/set the channel count to any value the user wants.
    (there are turnaround using complex filters, pans, amerge etc., but it is quite boring and requires the command line to be adapted to the input file properties)
    Reviewed-by: 's avatarMatthieu Bouron <matthieu.bouron@gmail.com>
    Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
    3eae34d5
mxfenc.c 85.5 KB