summaryrefslogtreecommitdiff
path: root/src/lib/dcp_encoder.cc
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2017-12-29 01:11:22 +0000
committerCarl Hetherington <cth@carlh.net>2017-12-29 01:11:22 +0000
commit60d528017a3ac1afdc30a3a000b28dda96a2175e (patch)
treedf6cad7c5ccd7f0da0802eb7dcf258df2bf1f7f9 /src/lib/dcp_encoder.cc
parentf8755c678d5b4b3d6b31761ef0ec13265190ca0c (diff)
Previously the code did not account for referenced audio, so far
as I can see. It decided which reel to write new audio to based on how many frames had been written to the current reel; this makes no sense for referred reels for which the player will emit no audio. This code looks at the audio timestamp instead.
Diffstat (limited to 'src/lib/dcp_encoder.cc')
-rw-r--r--src/lib/dcp_encoder.cc3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/lib/dcp_encoder.cc b/src/lib/dcp_encoder.cc
index 81464c8dc..76bfba5a2 100644
--- a/src/lib/dcp_encoder.cc
+++ b/src/lib/dcp_encoder.cc
@@ -121,11 +121,10 @@ DCPEncoder::video (shared_ptr<PlayerVideo> data, DCPTime time)
_j2k_encoder->encode (data, time);
}
-/** The audio data passed into this method must be contiguous and start from the last accurate seek time */
void
DCPEncoder::audio (shared_ptr<AudioBuffers> data, DCPTime time)
{
- _writer->write (data);
+ _writer->write (data, time);
shared_ptr<Job> job = _job.lock ();
DCPOMATIC_ASSERT (job);