summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2016-08-17 14:31:12 +0100
committerCarl Hetherington <cth@carlh.net>2016-08-17 14:31:12 +0100
commitd25b0a20c8e52b5b76fed0d9c08b972a363e6cc6 (patch)
treeac0318ff3c19432f3cf8877062469de17d4c32ee
parentc57c320a47aeb4d921ade5e3ed6a3f0ac59f6238 (diff)
Small libdcp API change.
-rw-r--r--cscript2
-rw-r--r--src/lib/film.cc3
-rw-r--r--src/lib/reel_writer.cc10
-rw-r--r--test/digest_test.cc6
-rw-r--r--test/import_dcp_test.cc2
5 files changed, 13 insertions, 10 deletions
diff --git a/cscript b/cscript
index 9dda13d3a..956a8f6fe 100644
--- a/cscript
+++ b/cscript
@@ -237,7 +237,7 @@ def dependencies(target):
ffmpeg_options = {}
return (('ffmpeg-cdist', '1d4a1a4', ffmpeg_options),
- ('libdcp', '81ed0eb'),
+ ('libdcp', '34f2b95'),
('libsub', '067c21c'))
def configure_options(target):
diff --git a/src/lib/film.cc b/src/lib/film.cc
index a41ab3c95..7d183d032 100644
--- a/src/lib/film.cc
+++ b/src/lib/film.cc
@@ -955,12 +955,13 @@ Film::cpls () const
try {
dcp::DCP dcp (*i);
dcp.read ();
+ DCPOMATIC_ASSERT (dcp.cpls().front()->file());
out.push_back (
CPLSummary (
i->path().leaf().string(),
dcp.cpls().front()->id(),
dcp.cpls().front()->annotation_text(),
- dcp.cpls().front()->file()
+ dcp.cpls().front()->file().get()
)
);
} catch (...) {
diff --git a/src/lib/reel_writer.cc b/src/lib/reel_writer.cc
index 9d2f9d0bc..c1ca2abb1 100644
--- a/src/lib/reel_writer.cc
+++ b/src/lib/reel_writer.cc
@@ -180,12 +180,13 @@ void
ReelWriter::check_existing_picture_asset ()
{
/* Try to open the existing asset */
- FILE* asset_file = fopen_boost (_picture_asset->file(), "rb");
+ DCPOMATIC_ASSERT (_picture_asset->file());
+ FILE* asset_file = fopen_boost (_picture_asset->file().get(), "rb");
if (!asset_file) {
- LOG_GENERAL ("Could not open existing asset at %1 (errno=%2)", _picture_asset->file().string(), errno);
+ LOG_GENERAL ("Could not open existing asset at %1 (errno=%2)", _picture_asset->file()->string(), errno);
return;
} else {
- LOG_GENERAL ("Opened existing asset at %1", _picture_asset->file().string());
+ LOG_GENERAL ("Opened existing asset at %1", _picture_asset->file()->string());
}
/* Offset of the last dcp::FrameInfo in the info file */
@@ -268,7 +269,8 @@ ReelWriter::finish ()
/* Hard-link any video asset file into the DCP */
if (_picture_asset) {
- boost::filesystem::path video_from = _picture_asset->file ();
+ DCPOMATIC_ASSERT (_picture_asset->file());
+ boost::filesystem::path video_from = _picture_asset->file().get();
boost::filesystem::path video_to;
video_to /= _film->dir (_film->dcp_name());
video_to /= video_asset_filename (_picture_asset, _reel_index, _reel_count, _content_summary);
diff --git a/test/digest_test.cc b/test/digest_test.cc
index 664f5bd20..7395fe468 100644
--- a/test/digest_test.cc
+++ b/test/digest_test.cc
@@ -79,13 +79,13 @@ BOOST_AUTO_TEST_CASE (digest_test)
list<shared_ptr<dcp::Reel> >::const_iterator i = reels.begin ();
BOOST_REQUIRE (i != reels.end ());
- BOOST_CHECK_EQUAL ((*i)->main_picture()->hash().get(), openssl_hash ((*i)->main_picture()->asset()->file ()));
+ BOOST_CHECK_EQUAL ((*i)->main_picture()->hash().get(), openssl_hash ((*i)->main_picture()->asset()->file().get()));
++i;
BOOST_REQUIRE (i != reels.end ());
- BOOST_CHECK_EQUAL ((*i)->main_picture()->hash().get(), openssl_hash ((*i)->main_picture()->asset()->file ()));
+ BOOST_CHECK_EQUAL ((*i)->main_picture()->hash().get(), openssl_hash ((*i)->main_picture()->asset()->file().get()));
++i;
BOOST_REQUIRE (i != reels.end ());
- BOOST_CHECK_EQUAL ((*i)->main_picture()->hash().get(), openssl_hash ((*i)->main_picture()->asset()->file ()));
+ BOOST_CHECK_EQUAL ((*i)->main_picture()->hash().get(), openssl_hash ((*i)->main_picture()->asset()->file().get()));
++i;
BOOST_REQUIRE (i == reels.end ());
}
diff --git a/test/import_dcp_test.cc b/test/import_dcp_test.cc
index 69ffa9cc4..cd0396d07 100644
--- a/test/import_dcp_test.cc
+++ b/test/import_dcp_test.cc
@@ -57,7 +57,7 @@ BOOST_AUTO_TEST_CASE (import_dcp_test)
dcp::EncryptedKDM kdm = A->make_kdm (
Config::instance()->decryption_chain()->leaf (),
vector<dcp::Certificate> (),
- A_dcp.cpls().front()->file (),
+ A_dcp.cpls().front()->file().get(),
dcp::LocalTime ("2014-07-21T00:00:00+00:00"),
dcp::LocalTime ("2024-07-21T00:00:00+00:00"),
dcp::MODIFIED_TRANSITIONAL_1