X-Git-Url: https://main.carlh.net/gitweb/?a=blobdiff_plain;f=src%2Flib%2Faudio_content.cc;h=014221f2e892afc95ef5f31d57aa3f4e44bea997;hb=7c73ec405fdb55bd78d82d764999b5af6d81e973;hp=b513fb443de0ec3e6631914bf3a1f1299a8bfe87;hpb=f67bc45820b4e56f90eecb97ba3b7762c119f9b5;p=dcpomatic.git diff --git a/src/lib/audio_content.cc b/src/lib/audio_content.cc index b513fb443..014221f2e 100644 --- a/src/lib/audio_content.cc +++ b/src/lib/audio_content.cc @@ -43,6 +43,7 @@ using boost::shared_ptr; using boost::dynamic_pointer_cast; using boost::optional; using dcp::raw_convert; +using namespace dcpomatic; /** Something stream-related has changed */ int const AudioContentProperty::STREAMS = 200; @@ -196,8 +197,7 @@ AudioContent::mapping () const int AudioContent::resampled_frame_rate (shared_ptr film) const { - /* Resample to a DCI-approved sample rate */ - double t = has_rate_above_48k() ? 96000 : 48000; + double t = film->audio_frame_rate (); FrameRateChange frc (film, _parent); @@ -264,19 +264,6 @@ AudioContent::processing_description (shared_ptr film) const return ""; } -/** @return true if any stream in this content has a sampling rate of more than 48kHz */ -bool -AudioContent::has_rate_above_48k () const -{ - BOOST_FOREACH (AudioStreamPtr i, streams ()) { - if (i->frame_rate() > 48000) { - return true; - } - } - - return false; -} - /** @return User-visible names of each of our audio channels */ vector AudioContent::channel_names () const