diff options
| author | Carl Hetherington <cth@carlh.net> | 2019-07-02 01:32:54 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2019-07-02 01:32:54 +0100 |
| commit | e6c828cbd577239e7c8e4c532161084a33843a0f (patch) | |
| tree | 2290dcdc341e47bcec5ed9f364be9f457b7bf3c0 /src/lib/dolby_cp750.cc | |
| parent | 8c0414a0dec9f444a80fc30c7be3bc82188446d4 (diff) | |
Add support for Datasat AP2x and USL sound processors when converting
fader position to gain. Stop storing a chosen processor in config;
instead, get the user to choose the processor when calculating gains.
Diffstat (limited to 'src/lib/dolby_cp750.cc')
| -rw-r--r-- | src/lib/dolby_cp750.cc | 32 |
1 files changed, 1 insertions, 31 deletions
diff --git a/src/lib/dolby_cp750.cc b/src/lib/dolby_cp750.cc index 3e2bb4346..380ab0564 100644 --- a/src/lib/dolby_cp750.cc +++ b/src/lib/dolby_cp750.cc @@ -25,37 +25,7 @@ using namespace std; DolbyCP750::DolbyCP750 () - : CinemaSoundProcessor ("dolby_cp750", _("Dolby CP650 and CP750")) + : CinemaSoundProcessor ("dolby_cp750", _("Dolby CP650 or CP750"), 4.0f, 20, 3.33333333333333333) { } - -float -DolbyCP750::db_for_fader_change (float from, float to) const -{ - float db = 0; - - if (from < to) { - if (from <= 4) { - float const t = min (to, 4.0f); - db += (t - from) * 20; - } - - if (to > 4) { - float const t = max (from, 4.0f); - db += (to - t) * 3.33333333333333333; - } - } else { - if (from >= 4) { - float const t = max (to, 4.0f); - db -= (from - t) * 3.33333333333333333; - } - - if (to < 4) { - float const t = min (from, 4.0f); - db -= (t - to) * 20; - } - } - - return db; -} |
