X-Git-Url: https://git.carlh.net/gitweb/?p=dcpomatic.git;a=blobdiff_plain;f=src%2Flib%2Fmatcher.cc;h=c56a563015b6eb617bf38535ff81be81c7cffeb0;hp=edbb084de7ebd6e4a872cdaf3218a00ab5199d03;hb=f861018389acd9d277fe34d7621182b9b54f977f;hpb=f09c6b53f155de601900afa90045059b20310c0d diff --git a/src/lib/matcher.cc b/src/lib/matcher.cc index edbb084de..c56a56301 100644 --- a/src/lib/matcher.cc +++ b/src/lib/matcher.cc @@ -41,7 +41,7 @@ Matcher::Matcher (shared_ptr log, int sample_rate, float frames_per_second) } void -Matcher::process_video (shared_ptr image, bool same, boost::shared_ptr sub, double t) +Matcher::process_video (shared_ptr image, bool same, boost::shared_ptr sub, double t) { _pixel_format = image->pixel_format (); _size = image->size (); @@ -90,11 +90,15 @@ Matcher::process_video (shared_ptr image, bool same, boost::shared_ptr b, double t) +Matcher::process_audio (shared_ptr b, double t) { _channels = b->channels (); - _log->log (String::compose ("Matcher audio @ %1 [video=%2, audio=%3, pending_audio=%4]", t, _video_frames, _audio_frames, _pending_audio.size())); + _log->log (String::compose ( + "Matcher audio (%1 frames) @ %2 [video=%3, audio=%4, pending_audio=%5]", + b->frames(), t, _video_frames, _audio_frames, _pending_audio.size() + ) + ); if (!_first_input) { _first_input = t; @@ -198,8 +202,9 @@ void Matcher::repeat_last_video () { if (!_last_image) { - _last_image.reset (new SimpleImage (_pixel_format.get(), _size.get(), true)); - _last_image->make_black (); + shared_ptr im (new SimpleImage (_pixel_format.get(), _size.get(), true)); + im->make_black (); + _last_image = im; } Video (_last_image, true, _last_subtitle);