+ if (examiner->has_atmos()) {
+ {
+ boost::mutex::scoped_lock lm (_mutex);
+ atmos = make_shared<AtmosContent>(this);
+ }
+ /* Setting length will cause calculations to be made based on edit rate, so that must
+ * be set up first otherwise hard-to-spot exceptions will be thrown.
+ */
+ atmos->set_edit_rate (examiner->atmos_edit_rate());
+ atmos->set_length (examiner->atmos_length());
+ }
+
+ list<shared_ptr<TextContent> > new_text;
+ for (int i = 0; i < static_cast<int>(TextType::COUNT); ++i) {
+ for (int j = 0; j < examiner->text_count(static_cast<TextType>(i)); ++j) {
+ auto c = make_shared<TextContent>(this, static_cast<TextType>(i), static_cast<TextType>(i));
+ if (i == static_cast<int>(TextType::CLOSED_CAPTION)) {
+ c->set_dcp_track (examiner->dcp_text_track(j));
+ }
+ new_text.push_back (c);
+ }
+ }