X-Git-Url: https://main.carlh.net/gitweb/?a=blobdiff_plain;f=src%2Flib%2Fwriter.cc;h=48f40334ab98825478545412a60d309da6ea98dd;hb=c9cadc1e53abb60a485a8a6de3eeecd54892b4d7;hp=9a0f83a22a5c184d68c3b5c5bc07789fe9fe3bca;hpb=1580bdc52a257870c908f32d2abe6fed84d83c50;p=dcpomatic.git diff --git a/src/lib/writer.cc b/src/lib/writer.cc index 9a0f83a22..48f40334a 100644 --- a/src/lib/writer.cc +++ b/src/lib/writer.cc @@ -269,8 +269,11 @@ Writer::write (shared_ptr audio, DCPTime const time) /* Easy case: we can write all the audio to this reel */ _audio_reel->write (audio); t = end; + } else if (_audio_reel->period().to <= t) { + /* This reel is entirely before the start of our audio; just skip the reel */ + ++_audio_reel; } else { - /* Split the audio into two and write the first part */ + /* This audio is over a reel boundary; split the audio into two and write the first part */ DCPTime part_lengths[2] = { _audio_reel->period().to - t, end - _audio_reel->period().to @@ -777,4 +780,7 @@ Writer::set_digest_progress (Job* job, float progress) } job->set_progress (min_progress); + + Waker waker; + waker.nudge (); }