summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2013-10-29 09:40:04 +0000
committerCarl Hetherington <cth@carlh.net>2013-10-29 09:40:04 +0000
commitfc5f541024dbc8269714dfb28384b41e1d97cb61 (patch)
tree5404a3ee49c3864ba53284597ef245dac35300a9
parent9d4fc8f37f8da52fcc2d2c63fe50bb2b034c1e50 (diff)
Fix audio weirdness when start-trimming.
-rw-r--r--ChangeLog4
-rw-r--r--src/lib/player.cc4
2 files changed, 6 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index a36166dd5..af3093205 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2013-10-29 Carl Hetherington <cth@carlh.net>
+
+ * Fix audio problems when start-trimming.
+
2013-10-28 Carl Hetherington <cth@carlh.net>
* Version 1.24 released.
diff --git a/src/lib/player.cc b/src/lib/player.cc
index 5c047d0eb..8370a3f9f 100644
--- a/src/lib/player.cc
+++ b/src/lib/player.cc
@@ -336,7 +336,7 @@ Player::process_audio (weak_ptr<Piece> weak_piece, shared_ptr<const AudioBuffers
return;
}
- Time time = content->position() + (content->audio_delay() * TIME_HZ / 1000) + relative_time;
+ Time time = content->position() + (content->audio_delay() * TIME_HZ / 1000) + relative_time - content->trim_start ();
/* Remap channels */
shared_ptr<AudioBuffers> dcp_mapped (new AudioBuffers (_film->audio_channels(), audio->frames()));
@@ -574,7 +574,7 @@ Player::emit_black ()
#ifdef DCPOMATIC_DEBUG
_last_video.reset ();
#endif
-
+
Video (_black_frame, EYES_BOTH, ColourConversion(), _last_emit_was_black, _video_position);
_video_position += _film->video_frames_to_time (1);
_last_emit_was_black = true;