Mercurial > hg > svgui
diff layer/WaveformLayer.cpp @ 1414:fa986b91d77f
Merge from branch fix-static-analysis
author | Chris Cannam |
---|---|
date | Wed, 09 Jan 2019 15:24:51 +0000 |
parents | c8a6fd3f9dff |
children | e866102db32a |
line wrap: on
line diff
--- a/layer/WaveformLayer.cpp Wed Jan 09 14:41:52 2019 +0000 +++ b/layer/WaveformLayer.cpp Wed Jan 09 15:24:51 2019 +0000 @@ -41,7 +41,7 @@ WaveformLayer::WaveformLayer() : SingleColourLayer(), - m_model(0), + m_model(nullptr), m_gain(1.0f), m_autoNormalize(false), m_showMeans(true), @@ -50,7 +50,7 @@ m_scale(LinearScale), m_middleLineHeight(0.5), m_aggressive(false), - m_cache(0), + m_cache(nullptr), m_cacheValid(false) { } @@ -218,7 +218,7 @@ if (name == "Gain") { return new LinearRangeMapper(-50, 50, -25, 25, tr("dB")); } - return 0; + return nullptr; } void @@ -919,9 +919,9 @@ case MeterScale: if (!mergingChannels) { - double r0 = fabs(AudioLevel::multiplier_to_preview + double r0 = std::abs(AudioLevel::multiplier_to_preview (range.min() * gain, m)); - double r1 = fabs(AudioLevel::multiplier_to_preview + double r1 = std::abs(AudioLevel::multiplier_to_preview (range.max() * gain, m)); rangeTop = std::max(r0, r1); meanTop = std::min(r0, r1);