-/** @return The sampling rate that we will resample the audio to */
-int
-Film::target_audio_sample_rate () const
-{
- if (has_audio ()) {
- return 0;
- }
-
- /* Resample to a DCI-approved sample rate */
- double t = dcp_audio_sample_rate (audio_frame_rate());
-
- FrameRateConversion frc (video_frame_rate(), dcp_frame_rate());
-
- /* Compensate if the DCP is being run at a different frame rate
- to the source; that is, if the video is run such that it will
- look different in the DCP compared to the source (slower or faster).
- skip/repeat doesn't come into effect here.
- */
-
- if (frc.change_speed) {
- t *= video_frame_rate() * frc.factor() / dcp_frame_rate();
- }
-
- return rint (t);
-}
-