A helper class that creates an AutomatableParameter and links it to a CachedValue, to make it easier to create and manage parameters whose values are stored as a property in a plugin's ValueTree state.
More...
#include <tracktion_ParameterHelpers.h>
|
AutomatableParameter::Ptr | parameter |
|
std::unique_ptr< juce::CachedValue< float > > | value |
|
A helper class that creates an AutomatableParameter and links it to a CachedValue, to make it easier to create and manage parameters whose values are stored as a property in a plugin's ValueTree state.
◆ ParameterWithStateValue() [1/3]
engine::ParameterWithStateValue::ParameterWithStateValue |
( |
| ) |
|
|
default |
◆ ParameterWithStateValue() [2/3]
engine::ParameterWithStateValue::ParameterWithStateValue |
( |
Plugin & |
, |
|
|
const juce::String & |
paramID, |
|
|
const juce::Identifier & |
propertyName, |
|
|
const juce::String & |
description, |
|
|
float |
defaultValue, |
|
|
juce::NormalisableRange< float > |
valueRange, |
|
|
std::function< juce::String(float)> |
valueToStringFunction = {} , |
|
|
std::function< float(const juce::String &)> |
stringToValueFunction = {} |
|
) |
| |
◆ ~ParameterWithStateValue()
engine::ParameterWithStateValue::~ParameterWithStateValue |
( |
| ) |
|
◆ ParameterWithStateValue() [3/3]
◆ operator=()
◆ getParameter()
AutomatableParameter & engine::ParameterWithStateValue::getParameter |
( |
| ) |
|
◆ getCachedValue()
juce::CachedValue< float > & engine::ParameterWithStateValue::getCachedValue |
( |
| ) |
|
◆ getCurrentValue()
float engine::ParameterWithStateValue::getCurrentValue |
( |
| ) |
const |
Returns the current value from the AutomatableParameter.
◆ setParameter()
void engine::ParameterWithStateValue::setParameter |
( |
float |
newValue, |
|
|
juce::NotificationType |
|
|
) |
| |
Sets a new value via the AutomatableParameter.
◆ reset()
void engine::ParameterWithStateValue::reset |
( |
| ) |
|
Releases the parameter and CachedValue.
◆ setFromValueTree()
void engine::ParameterWithStateValue::setFromValueTree |
( |
const juce::ValueTree & |
| ) |
|
Copies the matching property from the given ValueTree to this parameter.
◆ parameter
AutomatableParameter::Ptr engine::ParameterWithStateValue::parameter |
◆ value
std::unique_ptr<juce::CachedValue<float> > engine::ParameterWithStateValue::value |
The documentation for this struct was generated from the following file: