void
DCPEncoder::video (shared_ptr<PlayerVideo> data, DCPTime time)
{
- if (!_film->three_d()) {
- if (data->eyes() == Eyes::LEFT) {
- /* Use left-eye images for both eyes... */
- data->set_eyes (Eyes::BOTH);
- } else if (data->eyes() == Eyes::RIGHT) {
- /* ...and discard the right */
- return;
- }
- }
-
_j2k_encoder->encode (data, time);
}
void
Player::emit_video (shared_ptr<PlayerVideo> pv, DCPTime time)
{
+ if (!_film->three_d()) {
+ if (pv->eyes() == Eyes::LEFT) {
+ /* Use left-eye images for both eyes... */
+ pv->set_eyes (Eyes::BOTH);
+ } else if (pv->eyes() == Eyes::RIGHT) {
+ /* ...and discard the right */
+ return;
+ }
+ }
+
/* We need a delay to give a little wiggle room to ensure that relevent subtitles arrive at the
player before the video that requires them.
*/
}
+/** Test export of a 3D DCP in a 2D project */
+BOOST_AUTO_TEST_CASE (ffmpeg_encoder_3d_dcp_to_h264)
+{
+ auto dcp = make_shared<DCPContent>(TestPaths::private_data() / "XMenDarkPhoenix_TLR-12-3D_F_DE-XX_DE_51_2K_TCFG_20190227_TM_IOP-3D_OV");
+ auto film2 = new_test_film2 ("ffmpeg_encoder_3d_dcp_to_h264_export", {dcp});
+
+ auto job = make_shared<TranscodeJob> (film2);
+ FFmpegEncoder encoder (film2, job, "build/test/ffmpeg_encoder_3d_dcp_to_h264.mp4", ExportFormat::H264_AAC, true, false, false, 23);
+ encoder.go ();
+}
+
+
/** Test export of a 3D DCP in a 2D project */
BOOST_AUTO_TEST_CASE (ffmpeg_encoder_h264_test7)
{