Tweaks to free filter calculations but don't seem to be working correctly yet
This commit is contained in:
parent
3869745f44
commit
b672213e98
@ -423,8 +423,8 @@ inline void spectrum_do_free_filter(shared_envelope& env, int nfreq, double samp
|
|||||||
double binhz = (samplerate / 2.0) / nfreq * i;
|
double binhz = (samplerate / 2.0) / nfreq * i;
|
||||||
if (binhz >= 30.0)
|
if (binhz >= 30.0)
|
||||||
{
|
{
|
||||||
double norm = jmap<double>(binhz, 0.0, samplerate / 2.0, 0.0, 1.0);
|
double norm = 0.150542*log(0.0333333*binhz);
|
||||||
double db = jmap<double>(env->GetInterpolatedNodeValue(pow(norm, 0.25)), 0.0, 1.0, -36.0, 12.0);
|
double db = jmap<double>(env->GetInterpolatedNodeValue(norm), 0.0, 1.0, -36.0, 12.0);
|
||||||
freq2[i] = freq1[i] * Decibels::decibelsToGain(db);
|
freq2[i] = freq1[i] * Decibels::decibelsToGain(db);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -36,7 +36,8 @@ PaulstretchpluginAudioProcessorEditor::PaulstretchpluginAudioProcessorEditor(Pau
|
|||||||
m_free_filter_component.set_envelope(processor.m_free_filter_envelope);
|
m_free_filter_component.set_envelope(processor.m_free_filter_envelope);
|
||||||
m_free_filter_component.TimeFromNormalized = [this](double x)
|
m_free_filter_component.TimeFromNormalized = [this](double x)
|
||||||
{
|
{
|
||||||
return jmap<double>(pow(x, 4.0), 0.0, 1.0, 30.0, processor.getSampleRateChecked()/2.0);
|
//return jmap<double>(pow(x, 3.0), 0.0, 1.0, 30.0, processor.getSampleRateChecked()/2.0);
|
||||||
|
return 30.0*pow(1.05946309436, x*115.0);
|
||||||
};
|
};
|
||||||
m_free_filter_component.ValueFromNormalized = [this](double x)
|
m_free_filter_component.ValueFromNormalized = [this](double x)
|
||||||
{
|
{
|
||||||
|
@ -9,7 +9,7 @@ Released under GNU General Public License v.2 license.
|
|||||||
History :
|
History :
|
||||||
|
|
||||||
02-27-2018 1.0.3
|
02-27-2018 1.0.3
|
||||||
-Added free filter spectral processing module (may use lots of CPU)
|
-Added free filter spectral processing module
|
||||||
-Basic feature to allow offline rendering of the output of the plugin into a new file
|
-Basic feature to allow offline rendering of the output of the plugin into a new file
|
||||||
-Fixed bug with the number of harmonics parameter not getting saved and recalled
|
-Fixed bug with the number of harmonics parameter not getting saved and recalled
|
||||||
02-23-2018 1.0.2
|
02-23-2018 1.0.2
|
||||||
|
Loading…
x
Reference in New Issue
Block a user