summaryrefslogtreecommitdiff
path: root/src/lib/dcp_encoder.cc
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2020-06-19 13:30:02 +0200
committerCarl Hetherington <cth@carlh.net>2020-06-19 13:42:24 +0200
commita0c931b6bfb05b56996a75bbfcf378cd44ef18e1 (patch)
treed02d8cb5ef0fd0f8ce0751bf17fab9c98ffd1868 /src/lib/dcp_encoder.cc
parentcabe0934c60fb6e74bf4c3023bdcb5c68753e5d9 (diff)
Make Atmos content work more like other content. Now its MXFsencrypt-atmos
are re-written, meaning that they can be encrypted. This commit is mostly just for the backend. We also need a fair few checks/restrictions in the UI: - any present atmos content dictates the project frame rate - no mixed edit rates of atmos content - probably some other things I haven't thought of
Diffstat (limited to 'src/lib/dcp_encoder.cc')
-rw-r--r--src/lib/dcp_encoder.cc10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/lib/dcp_encoder.cc b/src/lib/dcp_encoder.cc
index d17c6c985..438a73fd6 100644
--- a/src/lib/dcp_encoder.cc
+++ b/src/lib/dcp_encoder.cc
@@ -64,6 +64,7 @@ DCPEncoder::DCPEncoder (shared_ptr<const Film> film, weak_ptr<Job> job)
_player_video_connection = _player->Video.connect (bind (&DCPEncoder::video, this, _1, _2));
_player_audio_connection = _player->Audio.connect (bind (&DCPEncoder::audio, this, _1, _2));
_player_text_connection = _player->Text.connect (bind (&DCPEncoder::text, this, _1, _2, _3, _4));
+ _player_atmos_connection = _player->Atmos.connect (bind (&DCPEncoder::atmos, this, _1, _2, _3));
BOOST_FOREACH (shared_ptr<const Content> c, film->content ()) {
BOOST_FOREACH (shared_ptr<TextContent> i, c->text) {
@@ -80,6 +81,7 @@ DCPEncoder::~DCPEncoder ()
_player_video_connection.release ();
_player_audio_connection.release ();
_player_text_connection.release ();
+ _player_atmos_connection.release ();
}
void
@@ -157,6 +159,14 @@ DCPEncoder::text (PlayerText data, TextType type, optional<DCPTextTrack> track,
}
}
+
+void
+DCPEncoder::atmos (shared_ptr<const dcp::AtmosFrame> data, DCPTime time, AtmosMetadata metadata)
+{
+ _writer->write (data, time, metadata);
+}
+
+
optional<float>
DCPEncoder::current_rate () const
{