32 const String& parameterName,
34 float defaultParameterValue,
39 defaultParameterValue,
40 attributes.getAudioParameterFloatAttributes()),
43 boolean (attributes.getBoolean())
79 ptr->onValueChanged = [
this] { parameterValueChanged ({}, {}); };
117 auto needsUpdateTestValue =
true;
119 if (!
needsUpdate.compare_exchange_strong (needsUpdateTestValue,
false))
122 if (
auto valueProperty =
tree.getPropertyPointer (
key))
177 template <
typename Fn>
204 std::atomic<bool>
needsUpdate {
true }, listenersNeedCalling {
true };
218 :
state (&stateIn) {}
220 void visit (std::unique_ptr<RangedAudioParameter> param)
const override
222 if (param ==
nullptr)
228 state->addParameterAdapter (*param);
229 state->processor.addParameter (param.release());
232 void visit (std::unique_ptr<AudioProcessorParameterGroup>
group)
const override
234 if (
group ==
nullptr)
240 for (
const auto param :
group->getParameters (
true))
244 state->addParameterAdapter (*rangedParam);
254 state->processor.addParameterGroup (move (
group));
261 item->accept (PushBackVisitor (*
this));
270 state.addListener (
this);
284 std::function<
String (
float)> valueToTextFunction,
285 std::function<
float (
const String&)> textToValueFunction,
286 bool isMetaParameter,
287 bool isAutomatableParameter,
288 bool isDiscreteParameter,
290 bool isBooleanParameter)
294 .withStringFromValueFunction ([
fn = std::move (valueToTextFunction)] (
float v,
int) {
return fn (
v); })
295 .withValueFromStringFunction (std::move (textToValueFunction))
296 .withMeta (isMetaParameter)
297 .withAutomatable (isAutomatableParameter)
298 .withDiscrete (isDiscreteParameter)
299 .withCategory (category)
300 .withBoolean (isBooleanParameter);
306 std::move (attributes)));
311 if (param ==
nullptr)
324 return param.release();
342 p->addListener (listener);
348 p->removeListener (listener);
354 if (adapter->tree.isValid())
363 return p->getRange();
371 return &adapter->getParameter();
379 return &
p->getRawDenormalisedValue();
388 return state.createCopy();
408 p->setDenormalisedValue (
p->tree.getProperty (
valuePropertyID,
p->getDenormalisedDefaultValue()));
419 for (
const auto& child :
state)
424 auto& adapter = *
p.second;
426 if (! adapter.tree.isValid())
429 adapter.tree.setProperty (
idPropertyID, adapter.getParameter().paramID,
nullptr);
430 state.appendChild (adapter.tree,
nullptr);
459 bool anyUpdated =
false;
476#if ! JUCE_AUDIOPROCESSOR_NO_GUI
477template <
typename Attachment,
typename Control>
479 const String& parameterID,
482 if (
auto* parameter = stateToUse.
getParameter (parameterID))
490 const String& parameterID,
497 const String& parameterID,
504 const String& parameterID,
515struct ParameterAdapterTests :
public UnitTest
517 ParameterAdapterTests()
521 void runTest()
override
523 beginTest (
"The default value is returned correctly");
529 AudioProcessorValueTreeState::ParameterAdapter adapter (param);
531 expectEquals (adapter.getDenormalisedDefaultValue(),
value);
534 test ({ -100, 100 }, 0);
535 test ({ -2.5, 12.5 }, 10);
538 beginTest (
"Denormalised parameter values can be retrieved");
540 const auto test = [&] (NormalisableRange<float> range,
float value)
542 AudioParameterFloat param ({}, {}, range, {});
543 AudioProcessorValueTreeState::ParameterAdapter adapter (param);
545 adapter.setDenormalisedValue (
value);
547 expectEquals (adapter.getDenormalisedValue(),
value);
548 expectEquals (adapter.getRawDenormalisedValue().load(),
value);
551 test ({ -20, -10 }, -15);
552 test ({ 0, 7.5 }, 2.5);
555 beginTest (
"Floats can be converted to text");
557 const auto test = [&] (NormalisableRange<float> range,
float value, String expected)
559 AudioParameterFloat param ({}, {}, range, {});
560 AudioProcessorValueTreeState::ParameterAdapter adapter (param);
562 expectEquals (adapter.getTextForDenormalisedValue (
value), expected);
565 test ({ -100, 100 }, 0,
"0.0000000");
566 test ({ -2.5, 12.5 }, 10,
"10.0000000");
567 test ({ -20, -10 }, -15,
"-15.0000000");
568 test ({ 0, 7.5 }, 2.5,
"2.5000000");
571 beginTest (
"Text can be converted to floats");
573 const auto test = [&] (NormalisableRange<float> range, String
text,
float expected)
575 AudioParameterFloat param ({}, {}, range, {});
576 AudioProcessorValueTreeState::ParameterAdapter adapter (param);
578 expectEquals (adapter.getDenormalisedValueForText (
text), expected);
581 test ({ -100, 100 },
"0.0", 0);
582 test ({ -2.5, 12.5 },
"10.0", 10);
583 test ({ -20, -10 },
"-15.0", -15);
584 test ({ 0, 7.5 },
"2.5", 2.5);
589static ParameterAdapterTests parameterAdapterTests;
593template <
typename ValueType>
594inline bool operator== (
const NormalisableRange<ValueType>&
a,
595 const NormalisableRange<ValueType>&
b)
597 return std::tie (
a.start,
a.end,
a.interval,
a.skew,
a.symmetricSkew)
598 == std::tie (
b.start,
b.end,
b.interval,
b.skew,
b.symmetricSkew);
601template <
typename ValueType>
602inline bool operator!= (
const NormalisableRange<ValueType>&
a,
603 const NormalisableRange<ValueType>&
b)
609class AudioProcessorValueTreeStateTests :
public UnitTest
612 using Parameter = AudioProcessorValueTreeState::Parameter;
613 using ParameterGroup = AudioProcessorParameterGroup;
614 using ParameterLayout = AudioProcessorValueTreeState::ParameterLayout;
615 using Attributes = AudioProcessorValueTreeStateParameterAttributes;
617 class TestAudioProcessor :
public AudioProcessor
620 TestAudioProcessor() =
default;
622 explicit TestAudioProcessor (ParameterLayout layout)
623 : state (*this,
nullptr,
"state", std::
move (layout)) {}
625 const String getName()
const override {
return {}; }
626 void prepareToPlay (
double,
int)
override {}
627 void releaseResources()
override {}
628 void processBlock (AudioBuffer<float>&, MidiBuffer&)
override {}
629 using AudioProcessor::processBlock;
630 double getTailLengthSeconds()
const override {
return {}; }
631 bool acceptsMidi()
const override {
return {}; }
632 bool producesMidi()
const override {
return {}; }
633 AudioProcessorEditor* createEditor()
override {
return {}; }
634 bool hasEditor()
const override {
return {}; }
635 int getNumPrograms()
override {
return 1; }
636 int getCurrentProgram()
override {
return {}; }
637 void setCurrentProgram (
int)
override {}
638 const String getProgramName (
int)
override {
return {}; }
639 void changeProgramName (
int,
const String&)
override {}
640 void getStateInformation (MemoryBlock&)
override {}
641 void setStateInformation (
const void*,
int)
override {}
643 AudioProcessorValueTreeState state { *
this,
nullptr };
646 struct Listener
final :
public AudioProcessorValueTreeState::Listener
648 void parameterChanged (
const String& idIn,
float valueIn)
override
659 AudioProcessorValueTreeStateTests()
660 : UnitTest (
"Audio Processor Value Tree State", UnitTestCategories::audioProcessorParameters)
664 void runTest()
override
666 ScopedJuceInitialiser_GUI scopedJuceInitialiser_gui;
668 beginTest (
"After calling createAndAddParameter, the number of parameters increases by one");
670 TestAudioProcessor proc;
672 proc.state.createAndAddParameter (std::make_unique<Parameter> (
675 NormalisableRange<float>(),
678 expectEquals (proc.getParameters().size(), 1);
681 beginTest (
"After creating a normal named parameter, we can later retrieve that parameter");
683 TestAudioProcessor proc;
685 const auto key =
"id";
686 const auto param = proc.state.createAndAddParameter (std::make_unique<Parameter> (
689 NormalisableRange<float>(),
692 expect (proc.state.getParameter (
key) == param);
695 beginTest (
"After construction, the value tree has the expected format");
697 TestAudioProcessor proc ({
698 std::make_unique<AudioProcessorParameterGroup> (
"A",
"",
"",
699 std::make_unique<AudioParameterBool> (
"a",
"",
false),
700 std::make_unique<AudioParameterFloat> (
"b",
"", NormalisableRange<float>{}, 0.0f)),
701 std::make_unique<AudioProcessorParameterGroup> (
"B",
"",
"",
702 std::make_unique<AudioParameterInt> (
"c",
"", 0, 1, 0),
703 std::make_unique<AudioParameterChoice> (
"d",
"", StringArray {
"foo",
"bar" }, 0)) });
705 const auto valueTree = proc.state.copyState();
707 expectEquals (valueTree.getNumChildren(), 4);
709 for (
auto child : valueTree)
711 expect (child.hasType (
"PARAM"));
712 expect (child.hasProperty (
"id"));
713 expect (child.hasProperty (
"value"));
717 beginTest (
"Meta parameters can be created");
719 TestAudioProcessor proc;
721 const auto key =
"id";
722 const auto param = proc.state.createAndAddParameter (std::make_unique<Parameter> (
725 NormalisableRange<float>(),
727 Attributes().withMeta (
true)));
729 expect (param->isMetaParameter());
732 beginTest (
"Automatable parameters can be created");
734 TestAudioProcessor proc;
736 const auto key =
"id";
737 const auto param = proc.state.createAndAddParameter (std::make_unique<Parameter> (
740 NormalisableRange<float>(),
742 Attributes().withAutomatable (
true)));
744 expect (param->isAutomatable());
747 beginTest (
"Discrete parameters can be created");
749 TestAudioProcessor proc;
751 const auto key =
"id";
752 const auto param = proc.state.createAndAddParameter (std::make_unique<Parameter> (
755 NormalisableRange<float>(),
757 Attributes().withDiscrete (
true)));
759 expect (param->isDiscrete());
762 beginTest (
"Custom category parameters can be created");
764 TestAudioProcessor proc;
766 const auto key =
"id";
767 const auto param = proc.state.createAndAddParameter (std::make_unique<Parameter> (
770 NormalisableRange<float>(),
772 Attributes().withCategory (AudioProcessorParameter::Category::inputMeter)));
774 expect (param->category == AudioProcessorParameter::Category::inputMeter);
777 beginTest (
"Boolean parameters can be created");
779 TestAudioProcessor proc;
781 const auto key =
"id";
782 const auto param = proc.state.createAndAddParameter (std::make_unique<Parameter> (
785 NormalisableRange<float>(),
787 Attributes().withBoolean (
true)));
789 expect (param->isBoolean());
792 beginTest (
"After creating a custom named parameter, we can later retrieve that parameter");
794 const auto key =
"id";
795 auto param = std::make_unique<AudioParameterBool> (
key,
"",
false);
796 const auto paramPtr = param.get();
798 TestAudioProcessor proc (std::move (param));
800 expect (proc.state.getParameter (
key) == paramPtr);
803 beginTest (
"After adding a normal parameter that already exists, the AudioProcessor parameters are unchanged");
805 TestAudioProcessor proc;
806 const auto key =
"id";
807 const auto param = proc.state.createAndAddParameter (std::make_unique<Parameter> (
810 NormalisableRange<float>(),
813 proc.state.createAndAddParameter (std::make_unique<Parameter> (
816 NormalisableRange<float>(),
819 expectEquals (proc.getParameters().size(), 1);
820 expect (proc.getParameters().getFirst() == param);
823 beginTest (
"After setting a parameter value, that value is reflected in the state");
825 TestAudioProcessor proc;
826 const auto key =
"id";
827 const auto param = proc.state.createAndAddParameter (std::make_unique<Parameter> (
830 NormalisableRange<float>(),
833 const auto value = 0.5f;
834 param->setValueNotifyingHost (
value);
836 expectEquals (proc.state.getRawParameterValue (
key)->load(),
value);
839 beginTest (
"After adding an APVTS::Parameter, its value is the default value");
841 TestAudioProcessor proc;
842 const auto key =
"id";
843 const auto value = 5.0f;
845 proc.state.createAndAddParameter (std::make_unique<Parameter> (
848 NormalisableRange<float> (0.0f, 100.0f, 10.0f),
851 expectEquals (proc.state.getRawParameterValue (
key)->load(),
value);
854 beginTest (
"Listeners receive notifications when parameters change");
857 TestAudioProcessor proc;
858 const auto key =
"id";
859 const auto param = proc.state.createAndAddParameter (std::make_unique<Parameter> (
862 NormalisableRange<float>(),
864 proc.state.addParameterListener (
key, &listener);
866 const auto value = 0.5f;
867 param->setValueNotifyingHost (
value);
869 expectEquals (listener.id, String { key });
870 expectEquals (listener.value,
value);
873 beginTest (
"Bool parameters have a range of 0-1");
875 const auto key =
"id";
877 TestAudioProcessor proc (std::make_unique<AudioParameterBool> (
key,
"",
false));
879 expect (proc.state.getParameterRange (
key) == NormalisableRange<float> (0.0f, 1.0f, 1.0f));
882 beginTest (
"Float parameters retain their specified range");
884 const auto key =
"id";
885 const auto range = NormalisableRange<float> { -100, 100, 0.7f, 0.2f,
true };
887 TestAudioProcessor proc (std::make_unique<AudioParameterFloat> (
key,
"", range, 0.0f));
889 expect (proc.state.getParameterRange (
key) == range);
892 beginTest (
"Int parameters retain their specified range");
894 const auto key =
"id";
895 const auto min = -27;
898 TestAudioProcessor proc (std::make_unique<AudioParameterInt> (
key,
"",
min,
max, 0));
900 expect (proc.state.getParameterRange (
key) == NormalisableRange<float> (float (
min),
float (
max), 1.0f));
903 beginTest (
"Choice parameters retain their specified range");
905 const auto key =
"id";
906 const auto choices = StringArray {
"",
"",
"" };
908 TestAudioProcessor proc (std::make_unique<AudioParameterChoice> (
key,
"", choices, 0));
910 expect (proc.state.getParameterRange (
key) == NormalisableRange<float> (0.0f, (
float) (choices.size() - 1), 1.0f));
911 expect (proc.state.getParameter (
key)->getNumSteps() == choices.size());
914 beginTest (
"When the parameter value is changed, normal parameter values are updated");
916 TestAudioProcessor proc;
917 const auto key =
"id";
918 const auto initialValue = 0.2f;
919 auto param = proc.state.createAndAddParameter (std::make_unique<Parameter> (
922 NormalisableRange<float>(),
924 proc.state.state = ValueTree {
"state" };
926 auto value = proc.state.getParameterAsValue (
key);
927 expectEquals (
float (
value.getValue()), initialValue);
929 const auto newValue = 0.75f;
932 expectEquals (param->getValue(), newValue);
933 expectEquals (proc.state.getRawParameterValue (
key)->load(), newValue);
936 beginTest (
"When the parameter value is changed, custom parameter values are updated");
938 const auto key =
"id";
939 const auto choices = StringArray (
"foo",
"bar",
"baz");
940 auto param = std::make_unique<AudioParameterChoice> (
key,
"", choices, 0);
941 const auto paramPtr = param.get();
942 TestAudioProcessor proc (std::move (param));
944 const auto newValue = 2.0f;
945 auto value = proc.state.getParameterAsValue (
key);
948 expectEquals (paramPtr->getCurrentChoiceName(), choices[
int (newValue)]);
949 expectEquals (proc.state.getRawParameterValue (
key)->load(), newValue);
952 beginTest (
"When the parameter value is changed, listeners are notified");
955 TestAudioProcessor proc;
956 const auto key =
"id";
957 proc.state.createAndAddParameter (std::make_unique<Parameter> (
960 NormalisableRange<float>(),
962 proc.state.addParameterListener (
key, &listener);
963 proc.state.state = ValueTree {
"state" };
965 const auto newValue = 0.75f;
966 proc.state.getParameterAsValue (
key) = newValue;
968 expectEquals (listener.value, newValue);
969 expectEquals (listener.id, String { key });
972 beginTest (
"When the parameter value is changed, listeners are notified");
974 const auto key =
"id";
975 const auto choices = StringArray {
"foo",
"bar",
"baz" };
977 TestAudioProcessor proc (std::make_unique<AudioParameterChoice> (
key,
"", choices, 0));
978 proc.state.addParameterListener (
key, &listener);
980 const auto newValue = 2.0f;
981 proc.state.getParameterAsValue (
key) = newValue;
983 expectEquals (listener.value, newValue);
984 expectEquals (listener.id, String (
key));
990static AudioProcessorValueTreeStateTests audioProcessorValueTreeStateTests;
#define final
Definition DistrhoDefines.h:74
#define nullptr
Definition DistrhoDefines.h:75
uint8_t a
Definition Spc_Cpu.h:141
Definition juce_AudioParameterFloat.h:45
AudioParameterFloat(const ParameterID ¶meterID, const String ¶meterName, NormalisableRange< float > normalisableRange, float defaultValue, const AudioParameterFloatAttributes &attributes={})
Definition juce_AudioParameterFloat.cpp:29
Definition juce_AudioProcessor.h:46
Definition juce_AudioProcessorParameter.h:294
Category
Definition juce_AudioProcessorParameter.h:231
const String paramID
Definition juce_AudioProcessorParameterWithID.h:161
std::unique_ptr< ComboBoxParameterAttachment > attachment
Definition juce_AudioProcessorValueTreeState.h:573
ComboBoxAttachment(AudioProcessorValueTreeState &stateToUse, const String ¶meterID, ComboBox &combo)
Definition juce_AudioProcessorValueTreeState.cpp:496
Definition juce_AudioProcessorValueTreeState.cpp:175
CriticalSection mutex
Definition juce_AudioProcessorValueTreeState.cpp:197
void call(Fn &&fn)
Definition juce_AudioProcessorValueTreeState.cpp:178
ListenerList< Listener > listeners
Definition juce_AudioProcessorValueTreeState.cpp:198
void add(Listener *l)
Definition juce_AudioProcessorValueTreeState.cpp:184
void remove(Listener *l)
Definition juce_AudioProcessorValueTreeState.cpp:190
Definition juce_AudioProcessorValueTreeState.cpp:66
std::atomic< float > unnormalisedValue
Definition juce_AudioProcessorValueTreeState.cpp:203
String getTextForDenormalisedValue(float value) const
Definition juce_AudioProcessorValueTreeState.cpp:107
float normalise(float denormalised) const
Definition juce_AudioProcessorValueTreeState.cpp:161
float denormalise(float normalised) const
Definition juce_AudioProcessorValueTreeState.cpp:156
ValueTree tree
Definition juce_AudioProcessorValueTreeState.cpp:138
bool flushToTree(const Identifier &key, UndoManager *um)
Definition juce_AudioProcessorValueTreeState.cpp:115
bool ignoreParameterChangedCallbacks
Definition juce_AudioProcessorValueTreeState.cpp:205
float getDenormalisedValueForText(const String &text) const
Definition juce_AudioProcessorValueTreeState.cpp:102
float getDenormalisedDefaultValue() const
Definition juce_AudioProcessorValueTreeState.cpp:92
std::atomic< bool > listenersNeedCalling
Definition juce_AudioProcessorValueTreeState.cpp:204
void parameterGestureChanged(int, bool) override
Definition juce_AudioProcessorValueTreeState.cpp:141
const NormalisableRange< float > & getRange() const
Definition juce_AudioProcessorValueTreeState.cpp:90
std::atomic< float > & getRawDenormalisedValue()
Definition juce_AudioProcessorValueTreeState.cpp:113
ParameterAdapter(RangedAudioParameter ¶meterIn)
Definition juce_AudioProcessorValueTreeState.cpp:71
void addListener(Listener *l)
Definition juce_AudioProcessorValueTreeState.cpp:84
void setDenormalisedValue(float value)
Definition juce_AudioProcessorValueTreeState.cpp:94
const RangedAudioParameter & getParameter() const
Definition juce_AudioProcessorValueTreeState.cpp:88
void removeListener(Listener *l)
Definition juce_AudioProcessorValueTreeState.cpp:85
RangedAudioParameter & parameter
Definition juce_AudioProcessorValueTreeState.cpp:201
float getDenormalisedValue() const
Definition juce_AudioProcessorValueTreeState.cpp:112
void parameterValueChanged(int, float) override
Definition juce_AudioProcessorValueTreeState.cpp:143
RangedAudioParameter & getParameter()
Definition juce_AudioProcessorValueTreeState.cpp:87
~ParameterAdapter() override
Definition juce_AudioProcessorValueTreeState.cpp:82
AudioProcessorValueTreeState::Listener Listener
Definition juce_AudioProcessorValueTreeState.cpp:68
LockedListeners listeners
Definition juce_AudioProcessorValueTreeState.cpp:202
void setNormalisedValue(float value)
Definition juce_AudioProcessorValueTreeState.cpp:166
std::atomic< bool > needsUpdate
Definition juce_AudioProcessorValueTreeState.cpp:204
Definition juce_AudioProcessorValueTreeState.h:453
bool isBoolean() const override
Definition juce_AudioProcessorValueTreeState.cpp:51
bool isDiscrete() const override
Definition juce_AudioProcessorValueTreeState.cpp:50
const bool discrete
Definition juce_AudioProcessorValueTreeState.h:523
void valueChanged(float) override
Definition juce_AudioProcessorValueTreeState.cpp:53
std::atomic< float > lastValue
Definition juce_AudioProcessorValueTreeState.h:524
Parameter(const ParameterID ¶meterID, const String ¶meterName, NormalisableRange< float > valueRange, float defaultValue, const AudioProcessorValueTreeStateParameterAttributes &attributes={})
Definition juce_AudioProcessorValueTreeState.cpp:31
float getDefaultValue() const override
Definition juce_AudioProcessorValueTreeState.cpp:47
std::function< void()> onValueChanged
Definition juce_AudioProcessorValueTreeState.h:520
const float unsnappedDefault
Definition juce_AudioProcessorValueTreeState.h:522
const bool boolean
Definition juce_AudioProcessorValueTreeState.h:523
int getNumSteps() const override
Definition juce_AudioProcessorValueTreeState.cpp:48
Definition juce_AudioProcessorValueTreeState.h:120
std::vector< std::unique_ptr< ParameterStorageBase > > parameters
Definition juce_AudioProcessorValueTreeState.h:207
SliderAttachment(AudioProcessorValueTreeState &stateToUse, const String ¶meterID, Slider &slider)
Definition juce_AudioProcessorValueTreeState.cpp:489
std::unique_ptr< SliderParameterAttachment > attachment
Definition juce_AudioProcessorValueTreeState.h:547
Definition juce_AudioProcessorValueTreeState.h:110
void valueTreePropertyChanged(ValueTree &, const Identifier &) override
Definition juce_AudioProcessorValueTreeState.cpp:437
Value getParameterAsValue(StringRef parameterID) const
Definition juce_AudioProcessorValueTreeState.cpp:351
UndoManager *const undoManager
Definition juce_AudioProcessorValueTreeState.h:417
RangedAudioParameter * getParameter(StringRef parameterID) const noexcept
Definition juce_AudioProcessorValueTreeState.cpp:368
void updateParameterConnectionsToChildTrees()
Definition juce_AudioProcessorValueTreeState.cpp:412
void addParameterAdapter(RangedAudioParameter &)
Definition juce_AudioProcessorValueTreeState.cpp:328
~AudioProcessorValueTreeState() override
Definition juce_AudioProcessorValueTreeState.cpp:273
AudioProcessor & processor
Definition juce_AudioProcessorValueTreeState.h:405
RangedAudioParameter * createAndAddParameter(const String ¶meterID, const String ¶meterName, const String &labelText, NormalisableRange< float > valueRange, float defaultValue, std::function< String(float)> valueToTextFunction, std::function< float(const String &)> textToValueFunction, bool isMetaParameter=false, bool isAutomatableParameter=true, bool isDiscrete=false, AudioProcessorParameter::Category parameterCategory=AudioProcessorParameter::genericParameter, bool isBoolean=false)
Definition juce_AudioProcessorValueTreeState.cpp:279
void addParameterListener(StringRef parameterID, Listener *listener)
Definition juce_AudioProcessorValueTreeState.cpp:339
NormalisableRange< float > getParameterRange(StringRef parameterID) const noexcept
Definition juce_AudioProcessorValueTreeState.cpp:360
AudioProcessorValueTreeState(AudioProcessor &processorToConnectTo, UndoManager *undoManagerToUse, const Identifier &valueTreeType, ParameterLayout parameterLayout)
Definition juce_AudioProcessorValueTreeState.cpp:209
const Identifier idPropertyID
Definition juce_AudioProcessorValueTreeState.h:646
void valueTreeRedirected(ValueTree &) override
Definition juce_AudioProcessorValueTreeState.cpp:449
void setNewState(ValueTree)
Definition juce_AudioProcessorValueTreeState.cpp:401
void replaceState(const ValueTree &newState)
Definition juce_AudioProcessorValueTreeState.cpp:391
bool flushParameterValuesToValueTree()
Definition juce_AudioProcessorValueTreeState.cpp:455
void removeParameterListener(StringRef parameterID, Listener *listener)
Definition juce_AudioProcessorValueTreeState.cpp:345
void valueTreeChildAdded(ValueTree &, ValueTree &) override
Definition juce_AudioProcessorValueTreeState.cpp:443
std::map< StringRef, std::unique_ptr< ParameterAdapter >, StringRefLessThan > adapterTable
Definition juce_AudioProcessorValueTreeState.h:653
void timerCallback() override
Definition juce_AudioProcessorValueTreeState.cpp:467
CriticalSection valueTreeChanging
Definition juce_AudioProcessorValueTreeState.h:655
ValueTree copyState()
Definition juce_AudioProcessorValueTreeState.cpp:384
const Identifier valueType
Definition juce_AudioProcessorValueTreeState.h:646
ValueTree state
Definition juce_AudioProcessorValueTreeState.h:414
ParameterAdapter * getParameterAdapter(StringRef) const
Definition juce_AudioProcessorValueTreeState.cpp:333
std::atomic< float > * getRawParameterValue(StringRef parameterID) const noexcept
Definition juce_AudioProcessorValueTreeState.cpp:376
const Identifier valuePropertyID
Definition juce_AudioProcessorValueTreeState.h:646
Definition juce_AudioProcessorValueTreeState.h:37
JUCE_NODISCARD auto withLabel(String x) const
Definition juce_AudioProcessorValueTreeState.h:49
Definition juce_ComboBox.h:49
Definition juce_ParameterAttachments.h:182
Definition juce_CriticalSection.h:43
GenericScopedLock< CriticalSection > ScopedLockType
Definition juce_CriticalSection.h:93
Definition juce_Identifier.h:39
Definition juce_ListenerList.h:70
Definition juce_NormalisableRange.h:40
Definition juce_AudioProcessorParameterWithID.h:33
Definition juce_RangedAudioParameter.h:98
float convertTo0to1(float v) const noexcept
Definition juce_RangedAudioParameter.cpp:39
int getNumSteps() const override
Definition juce_RangedAudioParameter.cpp:29
Definition juce_ScopedValueSetter.h:55
Definition juce_Slider.h:54
Definition juce_ParameterAttachments.h:134
Definition juce_String.h:53
Definition juce_StringRef.h:62
void stopTimer() noexcept
Definition juce_Timer.cpp:357
int getTimerInterval() const noexcept
Definition juce_Timer.h:116
void startTimerHz(int timerFrequencyHz) noexcept
Definition juce_Timer.cpp:349
void startTimer(int intervalInMilliseconds) noexcept
Definition juce_Timer.cpp:332
Definition juce_UndoManager.h:52
Definition juce_UnitTest.h:70
Definition juce_Value.h:51
Definition juce_ValueTree.h:72
ValueTree getParent() const noexcept
Definition juce_ValueTree.cpp:700
const var & getProperty(const Identifier &name) const noexcept
Definition juce_ValueTree.cpp:738
String toString() const
Definition juce_Variant.cpp:570
int * l
Definition inflate.c:1579
unsigned v[N_MAX]
Definition inflate.c:1584
static PuglViewHint int value
Definition pugl.h:1708
static uintptr_t parent
Definition pugl.h:1644
#define JUCE_BEGIN_IGNORE_WARNINGS_MSVC(warnings)
Definition juce_CompilerWarnings.h:198
#define JUCE_END_IGNORE_WARNINGS_MSVC
Definition juce_CompilerWarnings.h:199
float control
Definition lilv_test.c:1462
Definition juce_UnitTestCategories.h:27
void move(void *from, void *to)
Definition juce_FixedSizeFunction.h:53
Definition carla_juce.cpp:31
CriticalSection::ScopedLockType ScopedLock
Definition juce_CriticalSection.h:186
Type jlimit(Type lowerLimit, Type upperLimit, Type valueToConstrain) noexcept
Definition juce_MathsFunctions.h:262
std::unique_ptr< Attachment > makeAttachment(const AudioProcessorValueTreeState &stateToUse, const String ¶meterID, Control &control)
Definition juce_AudioProcessorValueTreeState.cpp:478
jack_client_t client jack_client_t client jack_client_t client jack_client_t JackInfoShutdownCallback void arg jack_client_t jack_port_t port void func jack_client_t const char const char unsigned long flags const jack_port_t port jack_client_t jack_port_id_t port_id const jack_port_t const char port_name const jack_port_t port void * ptr
Definition juce_linux_JackAudio.cpp:79
@ slider
Definition juce_AccessibilityRole.h:43
@ tree
Definition juce_AccessibilityRole.h:58
@ button
Definition juce_AccessibilityRole.h:38
@ group
Definition juce_AccessibilityRole.h:61
#define min(x, y)
Definition os.h:74
#define max(x, y)
Definition os.h:78
static int test(SerdEnv *env, bool top_level, bool pretty_numbers)
Definition sratom_test.c:79
Definition juce_AudioProcessorValueTreeState.h:350
Definition juce_AudioProcessorValueTreeState.h:167
const char const char const char const char char * fn
Definition swell-functions.h:168
const char * text
Definition swell-functions.h:167
uch * p
Definition crypt.c:594
ZCONST char * key
Definition crypt.c:587
typedef int(UZ_EXP MsgFn)()
#define void
Definition unzip.h:396