# HG changeset patch # User Chris Cannam # Date 1348691230 -3600 # Node ID 5bfc4930588df73b97b4b8f515e0233cba7f558e # Parent aca6e61eaea35a9c3f865a68521820b17cce7d3d Meter deflection fix due to Robin Gareus diff -r aca6e61eaea3 -r 5bfc4930588d base/AudioLevel.cpp --- a/base/AudioLevel.cpp Sat Jun 30 15:05:12 2012 +0100 +++ b/base/AudioLevel.cpp Wed Sep 26 21:27:10 2012 +0100 @@ -78,7 +78,7 @@ } else if (db < -60.0f) { def = (db + 70.0f) * 0.25f; } else if (db < -50.0f) { - def = (db + 60.0f) * 0.5f + 5.0f; + def = (db + 60.0f) * 0.5f + 2.5f; // corrected from 5.0f base, thanks Robin Gareus } else if (db < -40.0f) { def = (db + 50.0f) * 0.75f + 7.5f; } else if (db < -30.0f) { @@ -104,8 +104,8 @@ db = (def - 15.0f) / 1.5f - 40.0f; } else if (def >= 7.5f) { db = (def - 7.5f) / 0.75f - 50.0f; - } else if (def >= 5.0f) { - db = (def - 5.0f) / 0.5f - 60.0f; + } else if (def >= 2.5f) { + db = (def - 2.5f) / 0.5f - 60.0f; } else { db = (def / 0.25f) - 70.0f; }