X-Git-Url: https://git.carlh.net/gitweb/?a=blobdiff_plain;f=src%2Flib%2Fwriter.cc;h=d86a2ccf4ab032ba3a6d1f17ca232af7482bd02f;hb=565490c24a46d0aa941f75cf2a03b195246008b4;hp=10e4514fbcc134ef333d333d5086511b6b5660a3;hpb=2d99ab149d1eedb144337eb927c2ee1b92a046cc;p=dcpomatic.git diff --git a/src/lib/writer.cc b/src/lib/writer.cc index 10e4514fb..d86a2ccf4 100644 --- a/src/lib/writer.cc +++ b/src/lib/writer.cc @@ -106,6 +106,9 @@ void Writer::start () { _thread = new boost::thread (boost::bind (&Writer::thread, this)); +#ifdef DCPOMATIC_LINUX + pthread_setname_np (_thread->native_handle(), "writer"); +#endif } Writer::~Writer () @@ -634,6 +637,11 @@ Writer::write_cover_sheet () bool Writer::can_fake_write (Frame frame) const { + if (_film->encrypted()) { + /* We need to re-write the frame because the asset ID is embedded in the HMAC... I think... */ + return false; + } + /* We have to do a proper write of the first frame so that we can set up the JPEG2000 parameters in the asset writer. */ @@ -656,6 +664,8 @@ Writer::write (PlayerSubtitles subs, DCPTimePeriod period) ++_subtitle_reel; } + DCPOMATIC_ASSERT (_subtitle_reel != _reels.end()); + _subtitle_reel->write (subs); }