diff options
| author | Carl Hetherington <cth@carlh.net> | 2024-03-09 00:11:38 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2024-03-09 00:11:38 +0100 |
| commit | 80313b07095814f0178be70bc0651c1e052decea (patch) | |
| tree | 5ea002e29340ee342344affce277aa0cd941d7db /src/lib/dcp_content.cc | |
| parent | 82f87c7711fb664b06b04d44792ed3820b3d1e01 (diff) | |
| parent | 04b5957318df591f56e0a5d39720df143dc8230d (diff) | |
Merge branch 'main' into v2.17.x
Diffstat (limited to 'src/lib/dcp_content.cc')
| -rw-r--r-- | src/lib/dcp_content.cc | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/lib/dcp_content.cc b/src/lib/dcp_content.cc index 378ba1882..c459a9ece 100644 --- a/src/lib/dcp_content.cc +++ b/src/lib/dcp_content.cc @@ -723,6 +723,14 @@ DCPContent::can_reference_audio (shared_ptr<const Film> film, string& why_not) c return false; } + if (audio && audio->stream()) { + auto const channels = audio->stream()->channels(); + if (channels != film->audio_channels()) { + why_not = String::compose(_("it has a different number of audio channels than the project; set the project to have %1 channels."), channels); + return false; + } + } + auto part = [](shared_ptr<const Content> c) { return static_cast<bool>(c->audio) && !c->audio->mapping().mapped_output_channels().empty(); }; |
