{
if (_picture_asset_writer && !_picture_asset_writer->finalize ()) {
/* Nothing was written to the picture asset */
{
if (_picture_asset_writer && !_picture_asset_writer->finalize ()) {
/* Nothing was written to the picture asset */
if (_picture_asset) {
DCPOMATIC_ASSERT (_picture_asset->file());
boost::filesystem::path video_from = _picture_asset->file().get();
if (_picture_asset) {
DCPOMATIC_ASSERT (_picture_asset->file());
boost::filesystem::path video_from = _picture_asset->file().get();
video_to /= video_asset_filename (_picture_asset, _reel_index, _reel_count, _content_summary);
/* There may be an existing "to" file if we are recreating a DCP in the same place without
changing any video.
video_to /= video_asset_filename (_picture_asset, _reel_index, _reel_count, _content_summary);
/* There may be an existing "to" file if we are recreating a DCP in the same place without
changing any video.
string const aaf = audio_asset_filename (_sound_asset, _reel_index, _reel_count, _content_summary);
audio_to /= aaf;
string const aaf = audio_asset_filename (_sound_asset, _reel_index, _reel_count, _content_summary);
audio_to /= aaf;
string const aaf = atmos_asset_filename (_atmos_asset, _reel_index, _reel_count, _content_summary);
atmos_to /= aaf;
string const aaf = atmos_asset_filename (_atmos_asset, _reel_index, _reel_count, _content_summary);
atmos_to /= aaf;
list<ReferencedReelAsset> const & refs,
list<shared_ptr<Font> > const & fonts,
shared_ptr<const Film> film,
list<ReferencedReelAsset> const & refs,
list<shared_ptr<Font> > const & fonts,
shared_ptr<const Film> film,
boost::filesystem::create_directories (directory);
asset->write (directory / ("sub_" + asset->id() + ".xml"));
} else {
boost::filesystem::create_directories (directory);
asset->write (directory / ("sub_" + asset->id() + ".xml"));
} else {
-ReelWriter::create_reel_text (shared_ptr<dcp::Reel> reel, list<ReferencedReelAsset> const & refs, list<shared_ptr<Font> > const& fonts, int64_t duration) const
+ReelWriter::create_reel_text (
+ shared_ptr<dcp::Reel> reel,
+ list<ReferencedReelAsset> const & refs,
+ list<shared_ptr<Font> > const& fonts,
+ int64_t duration,
+ boost::filesystem::path output_dcp
+ ) const
- shared_ptr<dcp::ReelSubtitleAsset> subtitle = maybe_add_text<dcp::ReelSubtitleAsset> (_subtitle_asset, duration, reel, refs, fonts, film(), _period);
+ shared_ptr<dcp::ReelSubtitleAsset> subtitle = maybe_add_text<dcp::ReelSubtitleAsset> (
+ _subtitle_asset, duration, reel, refs, fonts, film(), _period, output_dcp
+ );
if (subtitle && !film()->subtitle_languages().empty()) {
subtitle->set_language (film()->subtitle_languages().front());
}
for (map<DCPTextTrack, shared_ptr<dcp::SubtitleAsset> >::const_iterator i = _closed_caption_assets.begin(); i != _closed_caption_assets.end(); ++i) {
shared_ptr<dcp::ReelClosedCaptionAsset> a = maybe_add_text<dcp::ReelClosedCaptionAsset> (
if (subtitle && !film()->subtitle_languages().empty()) {
subtitle->set_language (film()->subtitle_languages().front());
}
for (map<DCPTextTrack, shared_ptr<dcp::SubtitleAsset> >::const_iterator i = _closed_caption_assets.begin(); i != _closed_caption_assets.end(); ++i) {
shared_ptr<dcp::ReelClosedCaptionAsset> a = maybe_add_text<dcp::ReelClosedCaptionAsset> (
- i->second, duration, reel, refs, fonts, film(), _period
+ i->second, duration, reel, refs, fonts, film(), _period, output_dcp
{
LOG_GENERAL ("create_reel for %1-%2; %3 of %4", _period.from.get(), _period.to.get(), _reel_index, _reel_count);
shared_ptr<dcp::Reel> reel (new dcp::Reel());
shared_ptr<dcp::ReelPictureAsset> reel_picture_asset = create_reel_picture (reel, refs);
create_reel_sound (reel, refs);
{
LOG_GENERAL ("create_reel for %1-%2; %3 of %4", _period.from.get(), _period.to.get(), _reel_index, _reel_count);
shared_ptr<dcp::Reel> reel (new dcp::Reel());
shared_ptr<dcp::ReelPictureAsset> reel_picture_asset = create_reel_picture (reel, refs);
create_reel_sound (reel, refs);
- create_reel_text (reel, refs, fonts, reel_picture_asset->actual_duration());
+ create_reel_text (reel, refs, fonts, reel_picture_asset->actual_duration(), output_dcp);