X-Git-Url: https://git.carlh.net/gitweb/?a=blobdiff_plain;f=test%2Fscaling_test.cc;h=25359c605dd779f8c73c659793d93fdeb6be11b5;hb=65b331d32c383f3a9049f29bf03ab3fe3193b31a;hp=e37b609495d2a9f085643e762dd94a5b477aef07;hpb=dc7b2ee32fe8ce7c76c68dfc887dd561d1d552ff;p=dcpomatic.git diff --git a/test/scaling_test.cc b/test/scaling_test.cc index e37b60949..25359c605 100644 --- a/test/scaling_test.cc +++ b/test/scaling_test.cc @@ -26,20 +26,20 @@ #include "lib/ratio.h" #include "lib/film.h" #include "lib/dcp_content_type.h" +#include "lib/video_content.h" #include "test.h" using std::string; using boost::shared_ptr; -static void scaling_test_for (shared_ptr film, shared_ptr content, string image, string container) +static void scaling_test_for (shared_ptr film, shared_ptr content, string image, string container) { + content->video->set_scale (VideoContentScale (Ratio::from_id (image))); film->set_container (Ratio::from_id (container)); film->make_dcp (); wait_for_jobs (); - content->set_scale (VideoContentScale (Ratio::from_id (image))); - boost::filesystem::path ref; ref = "test"; ref /= "data"; @@ -64,15 +64,20 @@ BOOST_AUTO_TEST_CASE (scaling_test) film->examine_and_add_content (imc); wait_for_jobs (); - - imc->set_video_length (ContentTime::from_frames (1, 24)); + imc->video->set_video_length (1); + + /* F-133: 133 image in a flat container */ scaling_test_for (film, imc, "133", "185"); + /* F: flat image in a flat container */ scaling_test_for (film, imc, "185", "185"); + /* F-S: scope image in a flat container */ scaling_test_for (film, imc, "239", "185"); + /* S-133: 133 image in a scope container */ scaling_test_for (film, imc, "133", "239"); + /* S-F: flat image in a scope container */ scaling_test_for (film, imc, "185", "239"); + /* S: scope image in a scope container */ scaling_test_for (film, imc, "239", "239"); } -