summaryrefslogtreecommitdiff
path: root/src/lib/sndfile_content.cc
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2014-03-03 12:38:30 +0000
committerCarl Hetherington <cth@carlh.net>2014-03-03 12:38:30 +0000
commita2e3a20a441e604550f0036ca198d5d2122e16a7 (patch)
treec0da2b4ace57020b9973f20108e8bbf11ed4e444 /src/lib/sndfile_content.cc
parentc93389b617d2b1a4f5b36025e3097a9f03a7c9cf (diff)
Fix rounding of timecodes in at least some cases (#323).
Reported-by: Gérald Maruccia
Diffstat (limited to 'src/lib/sndfile_content.cc')
-rw-r--r--src/lib/sndfile_content.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib/sndfile_content.cc b/src/lib/sndfile_content.cc
index 796229777..98171a843 100644
--- a/src/lib/sndfile_content.cc
+++ b/src/lib/sndfile_content.cc
@@ -147,7 +147,7 @@ SndfileContent::full_length () const
shared_ptr<const Film> film = _film.lock ();
assert (film);
- OutputAudioFrame const len = audio_length() * output_audio_frame_rate() / content_audio_frame_rate ();
+ OutputAudioFrame const len = divide_with_round (audio_length() * output_audio_frame_rate(), content_audio_frame_rate ());
/* XXX: this depends on whether, alongside this audio, we are running video slower or faster than
it should be. The calculation above works out the output audio frames assuming that we are just