summaryrefslogtreecommitdiff
path: root/src/lib/writer.cc
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2013-09-19 21:39:01 +0100
committerCarl Hetherington <cth@carlh.net>2013-09-19 21:39:01 +0100
commitcd6fd2ab18bdc1364ede3a33773df4e3ad719efa (patch)
treeca7007518c890a37f2dd85493e7ee5ce27ffc4a0 /src/lib/writer.cc
parent8446a529b08d754c7ffe968baef54e5c115c26a5 (diff)
Various KDM and encryption fixes.
Diffstat (limited to 'src/lib/writer.cc')
-rw-r--r--src/lib/writer.cc17
1 files changed, 11 insertions, 6 deletions
diff --git a/src/lib/writer.cc b/src/lib/writer.cc
index 4f93373f7..37376ca23 100644
--- a/src/lib/writer.cc
+++ b/src/lib/writer.cc
@@ -79,8 +79,7 @@ Writer::Writer (shared_ptr<const Film> f, shared_ptr<Job> j)
_film->internal_video_mxf_dir (),
_film->internal_video_mxf_filename (),
_film->video_frame_rate (),
- _film->container()->size (_film->full_frame ()),
- _film->encrypted ()
+ _film->container()->size (_film->full_frame ())
)
);
@@ -90,13 +89,16 @@ Writer::Writer (shared_ptr<const Film> f, shared_ptr<Job> j)
_film->internal_video_mxf_dir (),
_film->internal_video_mxf_filename (),
_film->video_frame_rate (),
- _film->container()->size (_film->full_frame ()),
- _film->encrypted ()
+ _film->container()->size (_film->full_frame ())
)
);
}
+ if (_film->encrypted ()) {
+ _picture_asset->set_key (_film->key ());
+ }
+
_picture_asset_writer = _picture_asset->start_write (_first_nonexistant_frame > 0, _film->interop ());
_sound_asset.reset (
@@ -105,10 +107,13 @@ Writer::Writer (shared_ptr<const Film> f, shared_ptr<Job> j)
_film->audio_mxf_filename (),
_film->video_frame_rate (),
_film->audio_channels (),
- _film->audio_frame_rate (),
- _film->encrypted ()
+ _film->audio_frame_rate ()
)
);
+
+ if (_film->encrypted ()) {
+ _sound_asset->set_key (_film->key ());
+ }
_sound_asset_writer = _sound_asset->start_write (_film->interop ());