X-Git-Url: https://git.carlh.net/gitweb/?a=blobdiff_plain;f=src%2Flib%2Fdcp_examiner.cc;h=a0d13a7224bb42d090d0f26922f0ee8f99ef50f7;hb=387304bc9147933b68eda2b38ba8cac0d250e87e;hp=de7e9539976c08ff94c7dae4c567b625adb92197;hpb=a5095486e606adfe36de635a48710cf98872c1c6;p=dcpomatic.git diff --git a/src/lib/dcp_examiner.cc b/src/lib/dcp_examiner.cc index de7e95399..a0d13a722 100644 --- a/src/lib/dcp_examiner.cc +++ b/src/lib/dcp_examiner.cc @@ -81,7 +81,7 @@ DCPExaminer::DCPExaminer (shared_ptr content) throw DCPError (_("Mismatched video sizes in DCP")); } - _video_length += ContentTime::from_frames ((*i)->main_picture()->duration(), _video_frame_rate.get ()); + _video_length += (*i)->main_picture()->duration(); } if ((*i)->main_sound ()) { @@ -99,7 +99,7 @@ DCPExaminer::DCPExaminer (shared_ptr content) throw DCPError (_("Mismatched audio frame rates in DCP")); } - _audio_length += ContentTime::from_frames ((*i)->main_sound()->duration(), _video_frame_rate.get ()); + _audio_length += (*i)->main_sound()->duration(); } if ((*i)->main_subtitle ()) { @@ -117,12 +117,10 @@ DCPExaminer::DCPExaminer (shared_ptr content) shared_ptr mono = dynamic_pointer_cast (mxf); shared_ptr stereo = dynamic_pointer_cast (mxf); - shared_ptr image (new Image (PIX_FMT_RGB48LE, _video_size.get(), false)); - if (mono) { - mono->get_frame(0)->rgb_frame (reinterpret_cast (image->data()[0])); + mono->get_frame(0)->xyz_image (); } else { - stereo->get_frame(0)->rgb_frame (dcp::EYE_LEFT, reinterpret_cast (image->data()[0])); + stereo->get_frame(0)->xyz_image (dcp::EYE_LEFT); } }