" --right-eye next piece of content is for the right eye\n"
" --channel <channel> next piece of content should be mapped to audio channel L, R, C, Lfe, Ls or Rs\n"
" --gain next piece of content should have the given audio gain (in dB)\n"
+ " --cpl <id> CPL ID to use from the next piece of content (which is a DCP)\n"
" --kdm <file> KDM for next piece of content\n";
optional<dcp::Channel> channel;
optional<float> gain;
optional<boost::filesystem::path> kdm;
+ optional<std::string> cpl;
int i = 1;
while (i < argc) {
argument_option(i, argc, argv, "", "--channel", &claimed, &error, &channel, convert_channel);
argument_option(i, argc, argv, "", "--gain", &claimed, &error, &gain);
argument_option(i, argc, argv, "", "--kdm", &claimed, &error, &kdm, string_to_path);
+ argument_option(i, argc, argv, "", "--cpl", &claimed, &error, &cpl);
if (!claimed) {
if (a.length() > 2 && a.substr(0, 2) == "--") {
c.channel = channel;
c.gain = gain;
c.kdm = kdm;
+ c.cpl = cpl;
content.push_back (c);
next_frame_type = VideoFrameType::TWO_D;
channel = {};
BOOST_CHECK_CLOSE (*cc.content[1].gain, -6, 0.001);
BOOST_CHECK_EQUAL (cc.content[2].path, "sheila.wav");
BOOST_CHECK_CLOSE (*cc.content[2].gain, 2, 0.001);
+
+ cc = run("dcpomatic2_create --cpl 123456-789-0 dcp");
+ BOOST_REQUIRE_EQUAL(cc.content.size(), 1U);
+ BOOST_CHECK_EQUAL(cc.content[0].path, "dcp");
+ BOOST_REQUIRE(static_cast<bool>(cc.content[0].cpl));
+ BOOST_CHECK_EQUAL(*cc.content[0].cpl, "123456-789-0");
}