X-Git-Url: https://main.carlh.net/gitweb/?a=blobdiff_plain;f=test%2Fcpl_sar_test.cc;h=65f01900329f8e3bc562fb0cc93755579c2cf238;hb=9591b7486b0d56b7bc938f18a93e6d3a373e9d40;hp=55c3bcdc477019f4a7b458b902bf3f9fbe020e60;hpb=a641fdc912a3f0749015decdf9e23ff15186ef78;p=libdcp.git diff --git a/test/cpl_sar_test.cc b/test/cpl_sar_test.cc index 55c3bcdc..65f01900 100644 --- a/test/cpl_sar_test.cc +++ b/test/cpl_sar_test.cc @@ -1,5 +1,5 @@ /* - Copyright (C) 2014 Carl Hetherington + Copyright (C) 2014-2021 Carl Hetherington This file is part of libdcp. @@ -15,6 +15,20 @@ You should have received a copy of the GNU General Public License along with libdcp. If not, see . + + In addition, as a special exception, the copyright holders give + permission to link the code of portions of this program with the + OpenSSL library under certain conditions as described in each + individual source file, and distribute linked combinations + including the two. + + You must obey the GNU General Public License in all respects + for all of the code used other than OpenSSL. If you modify + file(s) with this exception, you may extend this exception to your + version of the file(s), but you are not obligated to do so. If you + do not wish to do so, delete this exception statement from your + version. If you delete this exception statement from all source + files in the program, then also delete it here. */ #include "cpl.h" @@ -25,7 +39,8 @@ #include using std::string; -using boost::shared_ptr; +using std::shared_ptr; +using std::make_shared; static void check (shared_ptr pa, dcp::Fraction far, string sar) @@ -33,7 +48,7 @@ check (shared_ptr pa, dcp::Fraction far, string sar) pa->set_screen_aspect_ratio (far); xmlpp::Document doc; xmlpp::Element* el = doc.create_root_node ("Test"); - pa->write_to_cpl (el, dcp::INTEROP); + pa->write_to_cpl (el, dcp::Standard::INTEROP); cxml::Node node (el); BOOST_CHECK_EQUAL (node.node_child("MainPicture")->string_child ("ScreenAspectRatio"), sar); @@ -46,11 +61,8 @@ check (shared_ptr pa, dcp::Fraction far, string sar) */ BOOST_AUTO_TEST_CASE (cpl_sar) { - shared_ptr pa ( - new dcp::ReelMonoPictureAsset ( - shared_ptr (new dcp::MonoPictureAsset ("test/ref/DCP/dcp_test1/video.mxf")), - 0 - ) + auto pa = make_shared( + make_shared("test/ref/DCP/dcp_test1/video.mxf"), 0 ); /* Easy ones */