diff options
| author | Carl Hetherington <cth@carlh.net> | 2023-07-25 11:04:30 +0200 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2023-08-06 22:05:03 +0200 |
| commit | 02d4493e593d567b210cd7f2b98d33a345867d1d (patch) | |
| tree | f3604e4104d6668c0eb67b4a7f29975876dd59a6 /src/lib/writer.cc | |
| parent | ea57d67cb7c7cd500d34bf783ed23c3dbc66b59b (diff) | |
Go back to respecting the user's choice for the number of audio channels in the MXF.
Diffstat (limited to 'src/lib/writer.cc')
| -rw-r--r-- | src/lib/writer.cc | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/lib/writer.cc b/src/lib/writer.cc index 71e9d579d..8b8ab89de 100644 --- a/src/lib/writer.cc +++ b/src/lib/writer.cc @@ -653,9 +653,12 @@ Writer::finish (boost::filesystem::path output_dcp) field = dcp::MCASoundField::FIVE_POINT_ONE; } - dcp::MainSoundConfiguration msc(field, MAX_DCP_AUDIO_CHANNELS); + auto const audio_channels = film()->audio_channels(); + dcp::MainSoundConfiguration msc(field, audio_channels); for (auto i: film()->mapped_audio_channels()) { - msc.set_mapping(i, static_cast<dcp::Channel>(i)); + if (i < audio_channels) { + msc.set_mapping(i, static_cast<dcp::Channel>(i)); + } } cpl->set_main_sound_configuration(msc); |
