2014-05-09 Carl Hetherington <cth@carlh.net>
+ * Fix crash on using content with more than 12 audio channels.
+
* Re-introduce ffprobe call when adding content.
2014-05-02 Carl Hetherington <cth@carlh.net>
using std::make_pair;
using std::pair;
using std::string;
+using std::min;
using boost::shared_ptr;
using boost::lexical_cast;
using boost::dynamic_pointer_cast;
set (0, libdcp::CENTRE, 1);
} else {
/* 1:1 mapping */
- for (int i = 0; i < _content_channels; ++i) {
+ for (int i = 0; i < min (_content_channels, MAX_DCP_AUDIO_CHANNELS); ++i) {
set (i, static_cast<libdcp::Channel> (i), 1);
}
}