+ throw DCPError (_("Mismatched audio sample rates in DCP"));
+ }
+
+ _audio_length += i->main_sound()->actual_duration();
+ _audio_language = try_to_parse_language (asset->language());
+ }
+
+ if (i->main_subtitle ()) {
+ if (!i->main_subtitle()->asset_ref().resolved()) {
+ /* We are missing this asset so we can't continue; examination will be repeated later */
+ _needs_assets = true;
+ return;
+ }
+
+ _text_count[static_cast<int>(TextType::OPEN_SUBTITLE)] = 1;
+ _open_subtitle_language = try_to_parse_language (i->main_subtitle()->language());
+ }
+
+ for (auto j: i->closed_captions()) {
+ if (!j->asset_ref().resolved()) {
+ /* We are missing this asset so we can't continue; examination will be repeated later */
+ _needs_assets = true;
+ return;