View Bug Details

IDProjectCategoryView StatusLast Update
0002631DCP-o-maticBugspublic2024-01-13 10:02
Reporteroverlookmotel Assigned Tocarl  
PrioritynormalSeverityminorReproducibilityalways
Status closedResolutionfixed 
PlatformMacOSOS XOS Version10.14
Product Version2.16.64 
Target Version2.16.67 
Summary0002631: Audio MXF in SMPTE DCP made with 2 audio channels cannot be read by ffmpeg/ffprobe
Description

We've received 3 DCPs recently which were made with DCP-o-matic 2.16.x (2.16.38 and 2.16.65 specifically) where we've found FFMPEG/FFPROBE are unable to read the audio MXF file.

In all 3 cases, the DCPs have 2 audio channels. They're also all SMPTE, though I'm not sure if that's relevant.

When running ffprobe on the audio MXF file in the DCP, it fails immediately with an error:

[mxf @ 0x7fb362904240] "OPAtom" with 2 ECs - assuming OP1a
[mxf @ 0x7fb362904240] AudioChannelLabelSubDescriptor has invalid MCA channel ID 3
/path/to/pcm.mxf: Invalid data found when processing input

ffmpeg also returns the same error.

I don't know for sure if this is a bug in DCP-o-matic, or in FFMPEG.

However, we've only seen this error with 2-channel DCPs made with DCP-o-matic. FFMPEG can successfully read 2-channel DCPs made with other software, and 6/8/16-channel DOM DCPs.

We are using FFMPEG 6.0 static builds downloaded from:
Mac OS (Intel): http://www.osxexperts.net/
Ubuntu (AMD64): https://johnvansickle.com/ffmpeg/

In case it's relevant, have reproduced this on:

  • Mac OS Ventura 13.4.1
  • Ubuntu 20.04

I've managed to produce a DCP which FFMPEG cannot read the audio MXF from with DCP-o-matic 2.16.65 (SMPTE DCP with 2-channel audio). Repro case here: https://drive.google.com/file/d/1OtgWSFHaDq7YekHwjK9e0sGG3Dtq5ite

Repro includes:

  • sources/timecode_25fps_1s1f.mov - Short ProResHQ file used to make DCP from
  • DOM project - DCP-o-matic project used to make DCP
  • DOM project/StereoTest_TST-1-25_F_XX-XX_MOS_2K_20231016_SMPTE_OV - the resulting DCP
  • ffprobe output.txt - ffprobe's output for the audio MXF file in this DCP

Googling the "AudioChannelLabelSubDescriptor" error doesn't bring up much, but this post on ffmpeg development list may shed some light:
https://patchwork.ffmpeg.org/project/ffmpeg/patch/20211129005930.7188-5-cus@passwd.hu/#68317

This appears to be the code in FFMPEG which produces the error:
https://github.com/FFmpeg/FFmpeg/blob/master/libavformat/mxfdec.c#L2542-L2559

TagsNo tags attached.
Branch2631-mca-again
Estimated weeks required
Estimated work requiredUndecided

Activities

overlookmotel

2023-10-16 17:48

developer   ~0006023

Don't know if this is related, but also noted that the CPL of the DCP seems to erroneously list 6 audio channels in the mca:MCASubDescriptors section (the DCP only has 2 channels):

<mca:MCASubDescriptors xmlns:mca="http://isdcf.com/ns/cplmd/mca" xmlns:r0="http://www.smpte-ra.org/reg/395/2014/13/1/aaf" xmlns:r1="http://www.smpte-ra.org/reg/335/2012">
  <r0:SoundfieldGroupLabelSubDescriptor>
    <r1:InstanceID>urn:uuid:264a6ae3-6cd5-4e36-a331-9d841ecc2963</r1:InstanceID>
    <r1:MCALabelDictionaryID>urn:smpte:ul:060e2b34.0401010d.03020201.00000000</r1:MCALabelDictionaryID>
    <r1:MCALinkID>urn:uuid:c9b841cf-6189-47b5-9f1f-188ef3933813</r1:MCALinkID>
    <r1:MCATagSymbol>sg51</r1:MCATagSymbol>
    <r1:MCATagName>5.1</r1:MCATagName>
    <r1:RFC5646SpokenLanguage>en-US</r1:RFC5646SpokenLanguage>
  </r0:SoundfieldGroupLabelSubDescriptor>
  <r0:AudioChannelLabelSubDescriptor>
    <r1:InstanceID>urn:uuid:ad53c174-79ee-46b3-82c7-9f91034c2c73</r1:InstanceID>
    <r1:MCALabelDictionaryID>urn:smpte:ul:060e2b34.0401010d.03020101.00000000</r1:MCALabelDictionaryID>
    <r1:MCALinkID>urn:uuid:5cd9de2a-3532-4e46-9576-d2d43d94887e</r1:MCALinkID>
    <r1:MCATagSymbol>chL</r1:MCATagSymbol>
    <r1:MCATagName>Left</r1:MCATagName>
    <r1:MCAChannelID>1</r1:MCAChannelID>
    <r1:RFC5646SpokenLanguage>en-US</r1:RFC5646SpokenLanguage>
    <r1:SoundfieldGroupLinkID>urn:uuid:c9b841cf-6189-47b5-9f1f-188ef3933813</r1:SoundfieldGroupLinkID>
  </r0:AudioChannelLabelSubDescriptor>
  <r0:AudioChannelLabelSubDescriptor>
    <r1:InstanceID>urn:uuid:90d3cd09-8c06-4e6d-9734-c778e3fcce24</r1:InstanceID>
    <r1:MCALabelDictionaryID>urn:smpte:ul:060e2b34.0401010d.03020102.00000000</r1:MCALabelDictionaryID>
    <r1:MCALinkID>urn:uuid:6f4895b4-8fe1-469d-95ab-e7371f02cb7f</r1:MCALinkID>
    <r1:MCATagSymbol>chR</r1:MCATagSymbol>
    <r1:MCATagName>Right</r1:MCATagName>
    <r1:MCAChannelID>2</r1:MCAChannelID>
    <r1:RFC5646SpokenLanguage>en-US</r1:RFC5646SpokenLanguage>
    <r1:SoundfieldGroupLinkID>urn:uuid:c9b841cf-6189-47b5-9f1f-188ef3933813</r1:SoundfieldGroupLinkID>
  </r0:AudioChannelLabelSubDescriptor>
  <r0:AudioChannelLabelSubDescriptor>
    <r1:InstanceID>urn:uuid:7c015df9-366e-4a45-b349-e42ca7e070bc</r1:InstanceID>
    <r1:MCALabelDictionaryID>urn:smpte:ul:060e2b34.0401010d.03020103.00000000</r1:MCALabelDictionaryID>
    <r1:MCALinkID>urn:uuid:5ff9a179-440a-4396-8a2b-2e02c925a575</r1:MCALinkID>
    <r1:MCATagSymbol>chC</r1:MCATagSymbol>
    <r1:MCATagName>Center</r1:MCATagName>
    <r1:MCAChannelID>3</r1:MCAChannelID>
    <r1:RFC5646SpokenLanguage>en-US</r1:RFC5646SpokenLanguage>
    <r1:SoundfieldGroupLinkID>urn:uuid:c9b841cf-6189-47b5-9f1f-188ef3933813</r1:SoundfieldGroupLinkID>
  </r0:AudioChannelLabelSubDescriptor>
  <r0:AudioChannelLabelSubDescriptor>
    <r1:InstanceID>urn:uuid:bcbe3d5f-0d71-419a-9e4b-2f6faccbc60f</r1:InstanceID>
    <r1:MCALabelDictionaryID>urn:smpte:ul:060e2b34.0401010d.03020104.00000000</r1:MCALabelDictionaryID>
    <r1:MCALinkID>urn:uuid:e753108c-2e7d-436a-a825-f911cddc74c3</r1:MCALinkID>
    <r1:MCATagSymbol>chLFE</r1:MCATagSymbol>
    <r1:MCATagName>LFE</r1:MCATagName>
    <r1:MCAChannelID>4</r1:MCAChannelID>
    <r1:RFC5646SpokenLanguage>en-US</r1:RFC5646SpokenLanguage>
    <r1:SoundfieldGroupLinkID>urn:uuid:c9b841cf-6189-47b5-9f1f-188ef3933813</r1:SoundfieldGroupLinkID>
  </r0:AudioChannelLabelSubDescriptor>
  <r0:AudioChannelLabelSubDescriptor>
    <r1:InstanceID>urn:uuid:226a124d-b1af-4182-9cf7-3acd7d914dbc</r1:InstanceID>
    <r1:MCALabelDictionaryID>urn:smpte:ul:060e2b34.0401010d.03020105.00000000</r1:MCALabelDictionaryID>
    <r1:MCALinkID>urn:uuid:74c78439-771c-4412-87bc-bdd265637c43</r1:MCALinkID>
    <r1:MCATagSymbol>chLs</r1:MCATagSymbol>
    <r1:MCATagName>Left Surround</r1:MCATagName>
    <r1:MCAChannelID>5</r1:MCAChannelID>
    <r1:RFC5646SpokenLanguage>en-US</r1:RFC5646SpokenLanguage>
    <r1:SoundfieldGroupLinkID>urn:uuid:c9b841cf-6189-47b5-9f1f-188ef3933813</r1:SoundfieldGroupLinkID>
  </r0:AudioChannelLabelSubDescriptor>
  <r0:AudioChannelLabelSubDescriptor>
    <r1:InstanceID>urn:uuid:0a46d7e0-1b0e-4a03-9eff-e704427cce75</r1:InstanceID>
    <r1:MCALabelDictionaryID>urn:smpte:ul:060e2b34.0401010d.03020106.00000000</r1:MCALabelDictionaryID>
    <r1:MCALinkID>urn:uuid:7fd77c71-54ff-4237-aa79-ff9b5ae43154</r1:MCALinkID>
    <r1:MCATagSymbol>chRs</r1:MCATagSymbol>
    <r1:MCATagName>Right Surround</r1:MCATagName>
    <r1:MCAChannelID>6</r1:MCAChannelID>
    <r1:RFC5646SpokenLanguage>en-US</r1:RFC5646SpokenLanguage>
    <r1:SoundfieldGroupLinkID>urn:uuid:c9b841cf-6189-47b5-9f1f-188ef3933813</r1:SoundfieldGroupLinkID>
  </r0:AudioChannelLabelSubDescriptor>
</mca:MCASubDescriptors>

overlookmotel

2023-10-16 17:57

developer   ~0006024

Update: I made a 2nd DCP identical to the repro case above but Interop instead of SMPTE. ffprobe can read the audio MXF in the Interop version without error. So it seems to be a SMPTE-only thing.

carl

2023-10-16 18:06

administrator   ~0006025

Thanks for the note. I've never found any definitive documentation on this. I'll try fixing DoM not to write more subdescriptors than there are channels.

overlookmotel

2023-10-16 18:31

developer   ~0006026

Thanks for swift reply Carl. Would that also possibly fix the problem of FFMPEG not being able to read the audio MXF? Or is that an unrelated problem? I have no idea what an "MCA channel ID" is!

carl

2023-10-16 22:38

administrator   ~0006027

It should fix the ffmpeg error - it's not unreasonably saying that we shouldn't have a descriptor for a channel that isn't there. MCA channel IDs are (so far as I can tell) a way to describe the function of a channel of audio, and probably how all this should have been done in the first place (i.e. maybe you have some channels, and then you have a list of descriptors which say what those channels are, then we wouldn't have all this messing about with empty channels and all that).

Sadly they are quite complicated and poorly documented so it's hard to know how to get them right. And I have a sneaking suspicion that most projection systems ignore them anyway.

overlookmotel

2023-10-17 14:44

developer   ~0006028

Thanks for the explanation.

By the way, we did have a cinema complaining a couple of months ago that a DCP we'd made with DOM 2.14.x (so before DOM added audio channel descriptors CPLs) didn't have a 5.1 mix, whereas the CPL title said it did. They were wrong - there was signal in all 6 channels - but they were completely adamant that there wasn't. It was a bit of a head-scratcher.

Turned out they weren't making this judgement based on actually playing the DCP in a screen. They'd concluded it wasn't 5.1 because their TMS software usually listed DCPs with a "5.1" icon where a 5.1 mix was present, and with this DCP it didn't say that.

I assume the only place the TMS could get the info on audio layouts is from the audio channel descriptor info in the CPL. So that'd suggest this info is getting at least some use in the field.

carl

2023-10-17 19:35

administrator   ~0006029

Interesting!

carl

2023-10-17 19:39

administrator   ~0006030

0a43629951e517d95ec791a361e7c7fa9c56d6cb

Bug History

Date Modified Username Field Change
2023-10-16 17:44 overlookmotel New Bug
2023-10-16 17:45 carl Assigned To => carl
2023-10-16 17:45 carl Status new => acknowledged
2023-10-16 17:45 carl Target Version => 2.16.67
2023-10-16 17:45 carl Estimated work required => Undecided
2023-10-16 17:48 overlookmotel Note Added: 0006023
2023-10-16 17:57 overlookmotel Note Added: 0006024
2023-10-16 17:59 carl Status acknowledged => confirmed
2023-10-16 18:06 carl Note Added: 0006025
2023-10-16 18:31 overlookmotel Note Added: 0006026
2023-10-16 19:19 carl Branch => 2631-mca-again
2023-10-16 22:38 carl Note Added: 0006027
2023-10-16 22:38 carl Status confirmed => tests running
2023-10-17 14:44 overlookmotel Note Added: 0006028
2023-10-17 19:35 carl Note Added: 0006029
2023-10-17 19:39 carl Status tests running => resolved
2023-10-17 19:39 carl Resolution open => fixed
2023-10-17 19:39 carl Note Added: 0006030
2024-01-13 10:02 carl Status resolved => closed