some app controls, format preserve, start of autotune speed
This commit is contained in:
@ -63,6 +63,7 @@ namespace ID
|
||||
#define PARAMETER_ID(str) static const ParameterID str { #str, 1 };
|
||||
|
||||
PARAMETER_ID(formantPreserve)
|
||||
PARAMETER_ID(autoTuneSpeed)
|
||||
PARAMETER_ID(mute)
|
||||
PARAMETER_ID(filterType)
|
||||
|
||||
@ -210,8 +211,8 @@ public:
|
||||
.5f)),
|
||||
|
||||
autoTuneSpeed(addToLayout<AudioParameterFloat>(layout,
|
||||
ID::formantPreserve,
|
||||
"AutoTuneSpeed",
|
||||
ID::autoTuneSpeed,
|
||||
"AutoTune Speed",
|
||||
NormalisableRange<float> {0.0f, 1.0f, .01f},
|
||||
.5f)),
|
||||
mute(addToLayout<AudioParameterBool>(layout, ID::mute, "Mute", false)),
|
||||
@ -318,6 +319,7 @@ void WebViewPluginAudioProcessor::processBlock(juce::AudioBuffer<float>& buffer,
|
||||
for (auto i = totalNumInputChannels; i < totalNumOutputChannels; ++i)
|
||||
buffer.clear(i, 0, buffer.getNumSamples());
|
||||
shifter.SetFormantPreserve(parameters.formantPreserve.get());
|
||||
shifter.SetAutoTuneSpeed(parameters.autoTuneSpeed.get());
|
||||
juce::AudioBuffer<float> const_buff;
|
||||
const_buff.makeCopyOf(buffer);
|
||||
shifter.Process(const_buff.getArrayOfReadPointers(), (float**)buffer.getArrayOfWritePointers(), buffer.getNumSamples());
|
||||
@ -463,6 +465,7 @@ private:
|
||||
WebViewPluginAudioProcessor& processorRef;
|
||||
|
||||
WebSliderRelay formantSliderRelay{ "formantSlider" };
|
||||
WebSliderRelay autoTuneSpeedSliderRelay{ "autoTuneSpeedSlider" };
|
||||
WebToggleButtonRelay muteToggleRelay{ "muteToggle" };
|
||||
WebComboBoxRelay filterTypeComboRelay{ "filterTypeCombo" };
|
||||
|
||||
@ -474,6 +477,7 @@ private:
|
||||
.withUserDataFolder(File::getSpecialLocation(File::SpecialLocationType::tempDirectory)))
|
||||
.withNativeIntegrationEnabled()
|
||||
.withOptionsFrom(formantSliderRelay)
|
||||
.withOptionsFrom(autoTuneSpeedSliderRelay)
|
||||
.withOptionsFrom(muteToggleRelay)
|
||||
.withOptionsFrom(filterTypeComboRelay)
|
||||
.withOptionsFrom(controlParameterIndexReceiver)
|
||||
@ -488,6 +492,7 @@ private:
|
||||
URL { localDevServerAddress }.getOrigin()) };
|
||||
|
||||
WebSliderParameterAttachment formantAttachment;
|
||||
WebSliderParameterAttachment autoTuneSpeedAttachment;
|
||||
WebToggleButtonParameterAttachment muteAttachment;
|
||||
WebComboBoxParameterAttachment filterTypeAttachment;
|
||||
|
||||
@ -616,6 +621,9 @@ WebViewPluginAudioProcessorEditor::WebViewPluginAudioProcessorEditor(WebViewPlug
|
||||
formantAttachment(*processorRef.state.getParameter(ID::formantPreserve.getParamID()),
|
||||
formantSliderRelay,
|
||||
processorRef.state.undoManager),
|
||||
autoTuneSpeedAttachment(*processorRef.state.getParameter(ID::autoTuneSpeed.getParamID()),
|
||||
autoTuneSpeedSliderRelay,
|
||||
processorRef.state.undoManager),
|
||||
muteAttachment(*processorRef.state.getParameter(ID::mute.getParamID()),
|
||||
muteToggleRelay,
|
||||
processorRef.state.undoManager),
|
||||
@ -625,8 +633,8 @@ WebViewPluginAudioProcessorEditor::WebViewPluginAudioProcessorEditor(WebViewPlug
|
||||
{
|
||||
addAndMakeVisible(webComponent);
|
||||
|
||||
webComponent.goToURL(localDevServerAddress);
|
||||
//webComponent.goToURL (WebBrowserComponent::getResourceProviderRoot());
|
||||
//webComponent.goToURL(localDevServerAddress);
|
||||
webComponent.goToURL (WebBrowserComponent::getResourceProviderRoot());
|
||||
|
||||
setSize(500, 500);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user