mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-10 23:44:24 +00:00
Began phasing out double_Pi and float_Pi in favour of MathConstants::pi. Also added MathConstants::twoPi
This commit is contained in:
parent
daab5147c2
commit
d0111a4f96
49 changed files with 307 additions and 292 deletions
|
|
@ -286,11 +286,11 @@ public:
|
|||
{
|
||||
auto structureUp = dsp::FilterDesign<SampleType>::designIIRLowpassHalfBandPolyphaseAllpassMethod (normalizedTransitionWidthUp, stopbandAttenuationdBUp);
|
||||
dsp::IIR::Coefficients<SampleType> coeffsUp = getCoefficients (structureUp);
|
||||
latency = static_cast<SampleType> (-(coeffsUp.getPhaseForFrequency (0.0001, 1.0)) / (0.0001 * 2 * double_Pi));
|
||||
latency = static_cast<SampleType> (-(coeffsUp.getPhaseForFrequency (0.0001, 1.0)) / (0.0001 * MathConstants<double>::twoPi));
|
||||
|
||||
auto structureDown = dsp::FilterDesign<SampleType>::designIIRLowpassHalfBandPolyphaseAllpassMethod (normalizedTransitionWidthDown, stopbandAttenuationdBDown);
|
||||
dsp::IIR::Coefficients<SampleType> coeffsDown = getCoefficients (structureDown);
|
||||
latency += static_cast<SampleType> (-(coeffsDown.getPhaseForFrequency (0.0001, 1.0)) / (0.0001 * 2 * double_Pi));
|
||||
latency += static_cast<SampleType> (-(coeffsDown.getPhaseForFrequency (0.0001, 1.0)) / (0.0001 * MathConstants<double>::twoPi));
|
||||
|
||||
for (auto i = 0; i < structureUp.directPath.size(); i++)
|
||||
coefficientsUp.add (structureUp.directPath[i].coefficients[0]);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue