| AAX SDK 2.8.0 Avid Audio Extensions Development Kit

- Welcome
- Manual
- Classes
- Files
- Lists
- Support

- File List
- File Members

Loading...
Searching...
No Matches
AAX_CParameter.h
Go to the documentation of this file.
1/*================================================================================================*/
2/*
3 *
4 * Copyright 2013-2017, 2019, 2021, 2023-2024 Avid Technology, Inc.
5 * All rights reserved.
6 *
7 * This file is part of the Avid AAX SDK.
8 *
9 * The AAX SDK is subject to commercial or open-source licensing.
10 *
11 * By using the AAX SDK, you agree to the terms of both the Avid AAX SDK License
12 * Agreement and Avid Privacy Policy.
13 *
14 * AAX SDK License: https://developer.avid.com/aax
15 * Privacy Policy: https://www.avid.com/legal/privacy-policy-statement
16 *
17 * Or: You may also use this code under the terms of the GPL v3 (see
18 * www.gnu.org/licenses).
19 *
20 * THE AAX SDK IS PROVIDED "AS IS" WITHOUT ANY WARRANTY, AND ALL WARRANTIES, WHETHER
21 * EXPRESSED OR IMPLIED, INCLUDING MERCHANTABILITY AND FITNESS FOR PURPOSE, ARE
22 * DISCLAIMED.
23 *
24 */
25
32/*================================================================================================*/
33
34
35#ifndef AAX_CPARAMETER_H
36#define AAX_CPARAMETER_H
37
38#include "AAX_Assert.h"
39#include "AAX_IParameter.h"
40#include "AAX_ITaperDelegate.h"
41#include "AAX_IDisplayDelegate.h"
42#include "AAX_IAutomationDelegate.h"
43#include "AAX_CString.h" //concrete class required for name.
44
45#include <cstring>
46#include <list>
47#include <map>
48
49
51#if 0
52#pragma mark -
53#endif
55
57
63 template <typename T>
64 class AAX_CParameterValue : public AAX_IParameterValue
65{
66 public:
67 enum Defaults {
68 eParameterDefaultMaxIdentifierSize = kAAX_ParameterIdentifierMaxSize,
69 eParameterDefaultMaxIdentifierLength = eParameterDefaultMaxIdentifierSize - 1 // NULL terminated
70 };
71
72 public:
73 AAX_DEFAULT_DTOR_OVERRIDE(AAX_CParameterValue);
74
75 AAX_DEFAULT_MOVE_CTOR(AAX_CParameterValue);
76 AAX_DEFAULT_MOVE_OPER(AAX_CParameterValue);
77
78 AAX_DELETE(AAX_CParameterValue& operator=(const AAX_CParameterValue&));
79
87 explicit AAX_CParameterValue(AAX_CParamID identifier);
88
96 explicit AAX_CParameterValue(AAX_CParamID identifier, const T& value);
97
100 explicit AAX_CParameterValue(const AAX_CParameterValue<T>& other);
101
102 public: // AAX_CParameterValue<T> implementation
105 const T& Get() const { return mValue; }
108 void Set(const T& inValue) { mValue = inValue; }
109
110 public: // AAX_IParameterValue implementation
111
112 AAX_IParameterValue* Clone() const AAX_OVERRIDE { return new AAX_CParameterValue<T>(*this); }
113 AAX_CParamID Identifier() const AAX_OVERRIDE { return mIdentifier; }
114
119 bool GetValueAsBool(bool* value) const AAX_OVERRIDE;
120 bool GetValueAsInt32(int32_t* value) const AAX_OVERRIDE;
121 bool GetValueAsFloat(float* value) const AAX_OVERRIDE;
122 bool GetValueAsDouble(double* value) const AAX_OVERRIDE;
123 bool GetValueAsString(AAX_IString* value) const AAX_OVERRIDE;
125
126 private:
127 void InitIdentifier(const char* inIdentifier);
128
129 private:
130 char mIdentifier[eParameterDefaultMaxIdentifierSize];
131 T mValue;
132};
133
134
136
137 template <typename T>
138 AAX_CParameterValue<T>::AAX_CParameterValue(AAX_CParamID identifier)
139: mValue()
140{
141 InitIdentifier(identifier);
142}
143
144 template <typename T>
145 AAX_CParameterValue<T>::AAX_CParameterValue(AAX_CParamID identifier, const T& value)
146: mValue(value)
147{
148 InitIdentifier(identifier);
149}
150
151 template <typename T>
152 AAX_CParameterValue<T>::AAX_CParameterValue(const AAX_CParameterValue<T>& other)
153: mValue(other.mValue)
154{
155 InitIdentifier(other.mIdentifier);
156}
157
158 template<typename T>
159 bool AAX_CParameterValue<T>::GetValueAsBool(bool* /*value*/) const
160{
161 return false;
162}
163 template <>
164 bool AAX_CParameterValue<bool>::GetValueAsBool(bool* value) const;
165
166
167 template<typename T>
168 bool AAX_CParameterValue<T>::GetValueAsInt32(int32_t* /*value*/) const
169{
170 return false;
171}
172 template<>
173 bool AAX_CParameterValue<int32_t>::GetValueAsInt32(int32_t* value) const;
174
175 template<typename T>
176 bool AAX_CParameterValue<T>::GetValueAsFloat(float* /*value*/) const
177{
178 return false;
179}
180 template<>
181 bool AAX_CParameterValue<float>::GetValueAsFloat(float* value) const;
182
183 template<typename T>
184 bool AAX_CParameterValue<T>::GetValueAsDouble(double* /*value*/) const
185{
186 return false;
187}
188 template<>
189 bool AAX_CParameterValue<double>::GetValueAsDouble(double* value) const;
190
191 template<typename T>
192 bool AAX_CParameterValue<T>::GetValueAsString(AAX_IString* /*value*/) const
193{
194 return false;
195}
196 template<>
197 bool AAX_CParameterValue<AAX_CString>::GetValueAsString(AAX_IString* value) const;
198
199 template<typename T>
200 void AAX_CParameterValue<T>::InitIdentifier(const char *inIdentifier)
201{
202
203 const size_t len = strlen(inIdentifier);
204 AAX_ASSERT(len < eParameterDefaultMaxIdentifierSize);
205 if (len < eParameterDefaultMaxIdentifierSize)
206 {
207 std::strncpy(mIdentifier, inIdentifier, 1+len);
208 mIdentifier[len] = 0;
209 }
210 else
211 {
212 std::strncpy(mIdentifier, inIdentifier, eParameterDefaultMaxIdentifierLength);
213 mIdentifier[eParameterDefaultMaxIdentifierLength] = 0;
214 }
215}
216
217
219#if 0
220#pragma mark -
221#endif
223
225
246 template <typename T>
247 class AAX_CParameter : public AAX_IParameter
248{
249 public:
250
251 enum Type {
252 eParameterTypeUndefined = 0,
253 eParameterTypeBool = 1,
254 eParameterTypeInt32 = 2,
255 eParameterTypeFloat = 3,
256 eParameterTypeCustom = 4
257 };
258
259 enum Defaults {
260 eParameterDefaultNumStepsDiscrete = 2,
261 eParameterDefaultNumStepsContinuous = 128
262 };
263
294 AAX_CParameter(AAX_CParamID identifier, const AAX_IString& name, T defaultValue, const AAX_ITaperDelegate<T>& taperDelegate, const AAX_IDisplayDelegate<T>& displayDelegate, bool automatable=false);
295
302 AAX_CParameter(const AAX_IString& identifier, const AAX_IString& name, T defaultValue, const AAX_ITaperDelegate<T>& taperDelegate, const AAX_IDisplayDelegate<T>& displayDelegate, bool automatable=false);
303
313 AAX_CParameter(const AAX_IString& identifier, const AAX_IString& name, T defaultValue, bool automatable=false);
314
325 AAX_CParameter(const AAX_IString& identifier, const AAX_IString& name, bool automatable=false);
326
328 AAX_DEFAULT_MOVE_CTOR(AAX_CParameter);
329 AAX_DEFAULT_MOVE_OPER(AAX_CParameter);
330
332 AAX_DELETE(AAX_CParameter());
333 AAX_DELETE(AAX_CParameter(const AAX_CParameter& other));
334 AAX_DELETE(AAX_CParameter& operator= (const AAX_CParameter& other));
335
340 ~AAX_CParameter() AAX_OVERRIDE;
341
342 AAX_IParameterValue* CloneValue() const AAX_OVERRIDE;
343
348 AAX_CParamID Identifier() const AAX_OVERRIDE;
349 void SetName(const AAX_CString& name) AAX_OVERRIDE;
350 const AAX_CString& Name() const AAX_OVERRIDE;
351 void AddShortenedName(const AAX_CString& name) AAX_OVERRIDE;
352 const AAX_CString& ShortenedName(int32_t iNumCharacters) const AAX_OVERRIDE;
353 void ClearShortenedNames() AAX_OVERRIDE;
355
360 void SetNormalizedDefaultValue(double normalizedDefault) AAX_OVERRIDE;
361 double GetNormalizedDefaultValue() const AAX_OVERRIDE;
362 void SetToDefaultValue() AAX_OVERRIDE;
363 void SetNormalizedValue(double newNormalizedValue) AAX_OVERRIDE;
364 double GetNormalizedValue() const AAX_OVERRIDE;
365 void SetNumberOfSteps(uint32_t numSteps) AAX_OVERRIDE;
366 uint32_t GetNumberOfSteps() const AAX_OVERRIDE;
367 uint32_t GetStepValue() const AAX_OVERRIDE;
368 double GetNormalizedValueFromStep(uint32_t iStep) const AAX_OVERRIDE;
369 uint32_t GetStepValueFromNormalizedValue(double normalizedValue) const AAX_OVERRIDE;
370 void SetStepValue(uint32_t iStep) AAX_OVERRIDE;
371 void SetType(AAX_EParameterType iControlType) AAX_OVERRIDE;
372 AAX_EParameterType GetType() const AAX_OVERRIDE;
373 void SetOrientation( AAX_EParameterOrientation iOrientation ) AAX_OVERRIDE;
374 AAX_EParameterOrientation GetOrientation() const AAX_OVERRIDE;
375 void SetTaperDelegate(AAX_ITaperDelegateBase& inTaperDelegate,bool inPreserveValue=true) AAX_OVERRIDE;
377
382 void SetDisplayDelegate(AAX_IDisplayDelegateBase& inDisplayDelegate) AAX_OVERRIDE;
383 bool GetValueString( AAX_CString* valueString) const AAX_OVERRIDE;
384 bool GetValueString(int32_t iMaxNumChars, AAX_CString* valueString) const AAX_OVERRIDE;
385 bool GetNormalizedValueFromBool(bool value, double *normalizedValue) const AAX_OVERRIDE;
386 bool GetNormalizedValueFromInt32(int32_t value, double *normalizedValue) const AAX_OVERRIDE;
387 bool GetNormalizedValueFromFloat(float value, double *normalizedValue) const AAX_OVERRIDE;
388 bool GetNormalizedValueFromDouble(double value, double *normalizedValue) const AAX_OVERRIDE;
389 bool GetNormalizedValueFromString(const AAX_CString& valueString, double *normalizedValue) const AAX_OVERRIDE;
390 bool GetBoolFromNormalizedValue(double normalizedValue, bool* value) const AAX_OVERRIDE;
391 bool GetInt32FromNormalizedValue(double normalizedValue, int32_t* value) const AAX_OVERRIDE;
392 bool GetFloatFromNormalizedValue(double normalizedValue, float* value) const AAX_OVERRIDE;
393 bool GetDoubleFromNormalizedValue(double normalizedValue, double* value) const AAX_OVERRIDE;
394 bool GetStringFromNormalizedValue(double normalizedValue, AAX_CString& valueString) const AAX_OVERRIDE;
395 bool GetStringFromNormalizedValue(double normalizedValue, int32_t iMaxNumChars, AAX_CString& valueString) const AAX_OVERRIDE;
396 bool SetValueFromString(const AAX_CString& newValueString) AAX_OVERRIDE;
398
403 void SetAutomationDelegate ( AAX_IAutomationDelegate * iAutomationDelegate ) AAX_OVERRIDE;
404 bool Automatable() const AAX_OVERRIDE;
405 void Touch() AAX_OVERRIDE;
406 void Release() AAX_OVERRIDE;
408
413 bool GetValueAsBool(bool* value) const AAX_OVERRIDE;
414 bool GetValueAsInt32(int32_t* value) const AAX_OVERRIDE;
415 bool GetValueAsFloat(float* value) const AAX_OVERRIDE;
416 bool GetValueAsDouble(double* value) const AAX_OVERRIDE;
417 bool GetValueAsString(AAX_IString* value) const AAX_OVERRIDE;
418 bool SetValueWithBool(bool value) AAX_OVERRIDE;
419 bool SetValueWithInt32(int32_t value) AAX_OVERRIDE;
420 bool SetValueWithFloat(float value) AAX_OVERRIDE;
421 bool SetValueWithDouble(double value) AAX_OVERRIDE;
422 bool SetValueWithString(const AAX_IString& value) AAX_OVERRIDE;
424
429 void UpdateNormalizedValue(double newNormalizedValue) AAX_OVERRIDE;
431
449 void SetValue(T newValue );
456 T GetValue() const;
465 void SetDefaultValue(T newDefaultValue);
472 T GetDefaultValue() const;
477 const AAX_ITaperDelegate<T>* TaperDelegate() const;
482 const AAX_IDisplayDelegate<T>* DisplayDelegate() const;
484
485protected:
486 AAX_CStringAbbreviations mNames;
487 bool mAutomatable;
488 uint32_t mNumSteps;
489 AAX_EParameterType mControlType;
490 AAX_EParameterOrientation mOrientation;
491 AAX_ITaperDelegate<T> * mTaperDelegate;
492 AAX_IDisplayDelegate<T> * mDisplayDelegate;
493 AAX_IAutomationDelegate * mAutomationDelegate;
494 bool mNeedNotify;
495
496 AAX_CParameterValue<T> mValue;
497 T mDefaultValue;
498
499private:
500 void InitializeNumberOfSteps();
501};
502
503
505
506template <typename T>
507 AAX_CParameter<T>::AAX_CParameter(AAX_CParamID identifier, const AAX_IString& name, T defaultValue, const AAX_ITaperDelegate<T>& taperDelegate, const AAX_IDisplayDelegate<T>& displayDelegate, bool automatable)
508: mNames(name)
509, mAutomatable(automatable)
510, mNumSteps(0) // Default set below for discrete/continuous
511, mControlType( AAX_eParameterType_Continuous )
512, mOrientation( AAX_eParameterOrientation_Default )
513, mTaperDelegate(taperDelegate.Clone())
514, mDisplayDelegate(displayDelegate.Clone())
515, mAutomationDelegate(0)
516, mNeedNotify(true)
517, mValue(identifier)
518, mDefaultValue(defaultValue)
519{
520 this->InitializeNumberOfSteps();
521 this->SetToDefaultValue();
522}
523
524 template <typename T>
525 AAX_CParameter<T>::AAX_CParameter(const AAX_IString& identifier, const AAX_IString& name, T defaultValue, const AAX_ITaperDelegate<T>& taperDelegate, const AAX_IDisplayDelegate<T>& displayDelegate, bool automatable)
526: mNames(name)
527, mAutomatable(automatable)
528, mNumSteps(0) // Default set below for discrete/continuous
529, mControlType( AAX_eParameterType_Continuous )
530, mOrientation( AAX_eParameterOrientation_Default )
531, mTaperDelegate(taperDelegate.Clone())
532, mDisplayDelegate(displayDelegate.Clone())
533, mAutomationDelegate(0)
534, mNeedNotify(true)
535, mValue(identifier.Get())
536, mDefaultValue(defaultValue)
537{
538 this->InitializeNumberOfSteps();
539 this->SetToDefaultValue();
540}
541
542 template <typename T>
543 AAX_CParameter<T>::AAX_CParameter(const AAX_IString& identifier, const AAX_IString& name, T defaultValue, bool automatable)
544: mNames(name)
545, mAutomatable(automatable)
546, mNumSteps(0)
547, mControlType( AAX_eParameterType_Continuous )
548, mOrientation( AAX_eParameterOrientation_Default )
549, mTaperDelegate(NULL)
550, mDisplayDelegate(NULL)
551, mAutomationDelegate(NULL)
552, mNeedNotify(true)
553, mValue(identifier.Get())
554, mDefaultValue(defaultValue)
555{
556 this->InitializeNumberOfSteps();
557 this->SetToDefaultValue();
558}
559
560 template <typename T>
561 AAX_CParameter<T>::AAX_CParameter(const AAX_IString& identifier, const AAX_IString& name, bool automatable)
562: mNames(name)
563, mAutomatable(automatable)
564, mNumSteps(0)
565, mControlType( AAX_eParameterType_Continuous )
566, mOrientation( AAX_eParameterOrientation_Default )
567, mTaperDelegate(NULL)
568, mDisplayDelegate(NULL)
569, mAutomationDelegate(NULL)
570, mNeedNotify(true)
571, mValue(identifier.Get())
572, mDefaultValue()
573{
574 this->InitializeNumberOfSteps();
575 this->SetToDefaultValue(); // WARNING: uninitialized default value
576}
577
578 template <typename T>
579 AAX_CParameter<T>::~AAX_CParameter()
580{
581 //Make sure to remove any registration with the token system.
582 SetAutomationDelegate(0);
583
584 delete mTaperDelegate;
585 mTaperDelegate = 0;
586 delete mDisplayDelegate;
587 mDisplayDelegate = 0;
588}
589
590 template <typename T>
591 AAX_IParameterValue* AAX_CParameter<T>::CloneValue() const
592{
593 return new AAX_CParameterValue<T>(mValue);
594}
595
596 template <typename T>
597 AAX_CParamID AAX_CParameter<T>::Identifier() const
598{
599 return mValue.Identifier();
600}
601
602 template <typename T>
603 void AAX_CParameter<T>::SetName(const AAX_CString& name)
604{
605 mNames.SetPrimary(name);
606 if (mAutomationDelegate) {
607 mAutomationDelegate->ParameterNameChanged(this->Identifier());
608 }
609}
610
611 template <typename T>
612 const AAX_CString& AAX_CParameter<T>::Name() const
613{
614 return mNames.Primary();
615}
616
617 template <typename T>
618 void AAX_CParameter<T>::AddShortenedName(const AAX_CString& name)
619{
620 mNames.Add(name);
621}
622
623 template <typename T>
624 const AAX_CString& AAX_CParameter<T>::ShortenedName(int32_t iNumCharacters) const
625{
626 return mNames.Get(iNumCharacters);
627}
628
629 template <typename T>
630 void AAX_CParameter<T>::ClearShortenedNames()
631{
632 mNames.Clear();
633}
634
635
636
637 template<typename T>
638 void AAX_CParameter<T>::SetValue( T newValue )
639{
640 double newNormalizedValue = mTaperDelegate->RealToNormalized(newValue);
641
642 // <DMT> Always go through the automation delegate even if the control isn't automatable to prevent fighting with other GUIs.
643 // Somewhere back in the automation delegate, or elsewhere in the system, it will determine the differences in behavior surrounding
644 // automation. The only reason that there wouldn't be an automation delegate is if this parameter has yet to be added to a
645 // ParameterManager. Let's put the null value guards in place, just in case, and also for unit tests.
646 if ( mAutomationDelegate )
647 {
648 //TODO: Create RAII utility class for touch/release
649
650 //Touch the control
651 Touch();
652
653 //Send that token.
654 mAutomationDelegate->PostSetValueRequest(Identifier(), newNormalizedValue );
655
656 //Release the control
657 Release();
658 }
659 else
660 {
661 mNeedNotify = true;
662
663 // In the rare case that an automation delegate doesn't exist, lets still set the value. It's possible that someone is trying to
664 // set the new value before adding the parameter to a parametermanager.
665 UpdateNormalizedValue(newNormalizedValue);
666 }
667}
668
669 template <typename T>
670 void AAX_CParameter<T>::UpdateNormalizedValue(double newNormalizedValue)
671{
672 T newValue = mTaperDelegate->NormalizedToReal(newNormalizedValue);
673 if (mNeedNotify || (mValue.Get() != newValue))
674 {
675 //Set the new value
676 mValue.Set(newValue);
677
678 //<DMT> Always notify that the value has changed through the automation delegate to guarantee that all control surfaces and other
679 // GUIs get their values updated.
680 if (mAutomationDelegate)
681 mAutomationDelegate->PostCurrentValue(Identifier(), newNormalizedValue);
682
683 // clear flag
684 mNeedNotify = false;
685 }
686}
687
688 template <typename T>
689 void AAX_CParameter<T>::InitializeNumberOfSteps()
690{
691 if (mNumSteps == 0) // If no explicit number of steps has been set...
692 {
693 switch (mControlType)
694 {
695 case AAX_eParameterType_Discrete:
696 {
697 // Discrete parameters default to binary unless
698 // otherwise specified
699 this->SetNumberOfSteps (eParameterDefaultNumStepsDiscrete);
700 break;
701 }
702 case AAX_eParameterType_Continuous:
703 {
704 // Defaulting to 128 steps to match one full rotation of
705 // Command|8 and similar surfaces, which query the num
706 // steps to determine tick values for rotary encoders
707 this->SetNumberOfSteps (eParameterDefaultNumStepsContinuous);
708 break;
709 }
710 default:
711 {
712 AAX_ASSERT (0); // Invalid type
713 break;
714 }
715 }
716 }
717}
718
719 template<typename T>
720T AAX_CParameter<T>::GetValue() const
721{
722 return mValue.Get();
723}
724
725
726 template<typename T>
727 bool AAX_CParameter<T>::GetValueAsBool(bool* value) const
728{
729 return mValue.GetValueAsBool(value);
730}
731
732 template<typename T>
733 bool AAX_CParameter<T>::GetValueAsInt32(int32_t* value) const
734{
735 return mValue.GetValueAsInt32(value);
736}
737
738 template<typename T>
739 bool AAX_CParameter<T>::GetValueAsFloat(float* value) const
740{
741 return mValue.GetValueAsFloat(value);
742}
743
744 template<typename T>
745 bool AAX_CParameter<T>::GetValueAsDouble(double* value) const
746{
747 return mValue.GetValueAsDouble(value);
748}
749
750 template<typename T>
751 bool AAX_CParameter<T>::GetValueAsString(AAX_IString* value) const
752{
753 bool result = false;
754 if (value)
755 {
756 AAX_CString valueString;
757 result = this->GetValueString(&valueString);
758 if (true == result)
759 {
760 *value = valueString;
761 }
762 }
763 return result;
764}
765
766 template<>
767 bool AAX_CParameter<AAX_CString>::GetValueAsString(AAX_IString* /*value*/) const;
768
769
770 template<typename T>
771 bool AAX_CParameter<T>::SetValueWithBool(bool /*value*/)
772{
773 return false;
774}
775 template<>
776 bool AAX_CParameter<bool>::SetValueWithBool(bool value);
777
778 template<typename T>
779 bool AAX_CParameter<T>::SetValueWithInt32(int32_t /*value*/)
780{
781 return false;
782}
783 template<>
784 bool AAX_CParameter<int32_t>::SetValueWithInt32(int32_t value);
785
786 template<typename T>
787 bool AAX_CParameter<T>::SetValueWithFloat(float /*value*/)
788{
789 return false;
790}
791 template<>
792 bool AAX_CParameter<float>::SetValueWithFloat(float value);
793
794 template<typename T>
795 bool AAX_CParameter<T>::SetValueWithDouble(double /*value*/)
796{
797 return false;
798}
799 template<>
800 bool AAX_CParameter<double>::SetValueWithDouble(double value);
801
802 template<typename T>
803 bool AAX_CParameter<T>::SetValueWithString(const AAX_IString& value)
804{
805 const AAX_CString valueString(value);
806 return this->SetValueFromString(valueString);
807}
808 template<>
809 bool AAX_CParameter<AAX_CString>::SetValueWithString(const AAX_IString& value);
810
811 template<typename T>
812 void AAX_CParameter<T>::SetNormalizedDefaultValue(double newNormalizedDefault)
813{
814 T newDefaultValue = mTaperDelegate->NormalizedToReal(newNormalizedDefault);
815 SetDefaultValue(newDefaultValue);
816}
817
818 template<typename T>
819 double AAX_CParameter<T>::GetNormalizedDefaultValue() const
820{
821 double normalizedDefault = mTaperDelegate->RealToNormalized(mDefaultValue);
822 return normalizedDefault;
823}
824
825 template<typename T>
826 void AAX_CParameter<T>::SetDefaultValue(T newDefaultValue)
827{
828 newDefaultValue = mTaperDelegate->ConstrainRealValue(newDefaultValue);
829 mDefaultValue = newDefaultValue;
830}
831
832 template<typename T>
833T AAX_CParameter<T>::GetDefaultValue() const
834{
835 return mDefaultValue;
836}
837
838 template<typename T>
839 void AAX_CParameter<T>::SetToDefaultValue()
840{
841 SetValue(mDefaultValue);
842}
843
844 template<typename T>
845 void AAX_CParameter<T>::SetNumberOfSteps(uint32_t numSteps)
846{
847 AAX_ASSERT(0 < numSteps);
848 if (0 < numSteps)
849 {
850 mNumSteps = numSteps;
851 }
852}
853
854 template<typename T>
855uint32_t AAX_CParameter<T>::GetNumberOfSteps() const
856{
857 return mNumSteps;
858}
859
860 template<typename T>
861uint32_t AAX_CParameter<T>::GetStepValue() const
862{
863 return GetStepValueFromNormalizedValue(this->GetNormalizedValue());
864}
865
866 template<typename T>
867 double AAX_CParameter<T>::GetNormalizedValueFromStep(uint32_t iStep) const
868{
869 double numSteps = (double) this->GetNumberOfSteps ();
870 if ( numSteps < 2.0 )
871 return 0.0;
872
873 double valuePerStep = 1.0 / ( numSteps - 1.0 );
874 double value = valuePerStep * (double) iStep;
875 if ( value < 0.0 )
876 value = 0.0;
877 else if ( value > 1.0 )
878 value = 1.0;
879
880 return value;
881}
882
883 template<typename T>
884uint32_t AAX_CParameter<T>::GetStepValueFromNormalizedValue(double normalizedValue) const
885{
886 double numSteps = (double) this->GetNumberOfSteps ();
887 if ( numSteps < 2.0 )
888 return 0;
889
890 double valuePerStep = 1.0 / ( numSteps - 1.0 );
891 double curStep = ( normalizedValue / valuePerStep ) + 0.5;
892 if ( curStep < 0.0 )
893 curStep = 0.0;
894 else if ( curStep > (double) ( numSteps - 1.0 ) )
895 curStep = (double) ( numSteps - 1.0 );
896
897 return (uint32_t) curStep;
898}
899
900 template<typename T>
901 void AAX_CParameter<T>::SetStepValue(uint32_t iStep)
902{
903 double numSteps = (double) this->GetNumberOfSteps ();
904 if ( numSteps < 2.0 )
905 return;
906
907 this->SetNormalizedValue ( GetNormalizedValueFromStep(iStep) );
908}
909
910 template<typename T>
911 void AAX_CParameter<T>::SetType(AAX_EParameterType iControlType)
912{
913 mControlType = iControlType;
914}
915
916 template<typename T>
917 AAX_EParameterType AAX_CParameter<T>::GetType() const
918{
919 return mControlType;
920}
921
922 template<typename T>
923 void AAX_CParameter<T>::SetOrientation(AAX_EParameterOrientation iOrientation)
924{
925 mOrientation = iOrientation;
926}
927
928 template<typename T>
929 AAX_EParameterOrientation AAX_CParameter<T>::GetOrientation() const
930{
931 return mOrientation;
932}
933
934 template<typename T>
935 void AAX_CParameter<T>::SetNormalizedValue(double normalizedNewValue)
936{
937 T newValue = mTaperDelegate->NormalizedToReal(normalizedNewValue);
938 this->SetValue(newValue);
939}
940
941 template<typename T>
942 double AAX_CParameter<T>::GetNormalizedValue() const
943{
944 T val = GetValue();
945 return mTaperDelegate->RealToNormalized(val);
946}
947
948
949 template<typename T>
950 bool AAX_CParameter<T>::GetValueString(AAX_CString* valueString) const
951{
952 return mDisplayDelegate->ValueToString(this->GetValue(), valueString);
953}
954
955 template<typename T>
956 bool AAX_CParameter<T>::GetValueString(int32_t /*iMaxNumChars*/, AAX_CString* valueString) const
957{
958 return mDisplayDelegate->ValueToString(this->GetValue(), valueString);
959}
960
961 template <typename T>
962 bool AAX_CParameter<T>::GetNormalizedValueFromBool(bool /*value*/, double * /*normalizedValue*/) const
963{
964 return false;
965}
966 template <>
967 bool AAX_CParameter<bool>::GetNormalizedValueFromBool(bool value, double *normalizedValue) const;
968
969 template <typename T>
970 bool AAX_CParameter<T>::GetNormalizedValueFromInt32(int32_t /*value*/, double * /*normalizedValue*/) const
971{
972 return false;
973}
974 template <>
975 bool AAX_CParameter<int32_t>::GetNormalizedValueFromInt32(int32_t value, double *normalizedValue) const;
976
977 template <typename T>
978 bool AAX_CParameter<T>::GetNormalizedValueFromFloat(float /*value*/, double * /*normalizedValue*/) const
979{
980 return false;
981}
982 template <>
983 bool AAX_CParameter<float>::GetNormalizedValueFromFloat(float value, double *normalizedValue) const;
984
985 template <typename T>
986 bool AAX_CParameter<T>::GetNormalizedValueFromDouble(double /*value*/, double * /*normalizedValue*/) const
987{
988 return false;
989}
990 template <>
991 bool AAX_CParameter<double>::GetNormalizedValueFromDouble(double value, double *normalizedValue) const;
992
993 template <typename T>
994 bool AAX_CParameter<T>::GetNormalizedValueFromString(const AAX_CString& valueString, double *normalizedValue) const
995{
996 //First, convert the string to a value using the wrapped parameter's display delegate.
997 T value;
998 if (!mDisplayDelegate->StringToValue(valueString, &value))
999 return false;
1000
1001 //Then use the wrapped parameter's taper delegate to convert to a normalized representation.
1002 //If the parameter is out of range, the normalizedValue will be clamped just to be safe.
1003 *normalizedValue = mTaperDelegate->RealToNormalized(value);
1004 return true;
1005}
1006
1007 template<typename T>
1008 bool AAX_CParameter<T>::GetBoolFromNormalizedValue(double /*inNormalizedValue*/, bool* /*value*/) const
1009{
1010 return false;
1011}
1012 template <>
1013 bool AAX_CParameter<bool>::GetBoolFromNormalizedValue(double inNormalizedValue, bool* value) const;
1014
1015
1016 template<typename T>
1017 bool AAX_CParameter<T>::GetInt32FromNormalizedValue(double /*inNormalizedValue*/, int32_t* /*value*/) const
1018{
1019 return false;
1020}
1021 template<>
1022 bool AAX_CParameter<int32_t>::GetInt32FromNormalizedValue(double inNormalizedValue, int32_t* value) const;
1023
1024 template<typename T>
1025 bool AAX_CParameter<T>::GetFloatFromNormalizedValue(double /*inNormalizedValue*/, float* /*value*/) const
1026{
1027 return false;
1028}
1029 template<>
1030 bool AAX_CParameter<float>::GetFloatFromNormalizedValue(double inNormalizedValue, float* value) const;
1031
1032 template<typename T>
1033 bool AAX_CParameter<T>::GetDoubleFromNormalizedValue(double /*inNormalizedValue*/, double* /*value*/) const
1034{
1035 return false;
1036}
1037 template<>
1038 bool AAX_CParameter<double>::GetDoubleFromNormalizedValue(double inNormalizedValue, double* value) const;
1039
1040 template <typename T>
1041 bool AAX_CParameter<T>::GetStringFromNormalizedValue(double normalizedValue, AAX_CString& valueString) const
1042{
1043 T value = mTaperDelegate->NormalizedToReal(normalizedValue);
1044 if (!mDisplayDelegate->ValueToString(value, &valueString))
1045 return false;
1046
1047 //If the parameter is out of range, we should probably return false, even though we clamped the normalizedValue already just to be safe.
1048 if ((value > mTaperDelegate->GetMaximumValue()) || (value < mTaperDelegate->GetMinimumValue()))
1049 return false;
1050 return true;
1051}
1052
1053 template <typename T>
1054 bool AAX_CParameter<T>::GetStringFromNormalizedValue(double normalizedValue, int32_t iMaxNumChars, AAX_CString& valueString) const
1055{
1056 T value = mTaperDelegate->NormalizedToReal(normalizedValue);
1057 if (!mDisplayDelegate->ValueToString(value, iMaxNumChars, &valueString))
1058 return false;
1059
1060 //If the parameter is out of range, we should probably return false, even though we clamped the normalizedValue already just to be safe.
1061 if ((value > mTaperDelegate->GetMaximumValue()) || (value < mTaperDelegate->GetMinimumValue()))
1062 return false;
1063 return true;
1064}
1065
1066 template<typename T>
1067 bool AAX_CParameter<T>::SetValueFromString(const AAX_CString& newValueString)
1068{
1069 T newValue;
1070 if (!mDisplayDelegate->StringToValue(newValueString, &newValue))
1071 return false;
1072 SetValue(newValue);
1073 return true;
1074}
1075
1076 template<typename T>
1077 void AAX_CParameter<T>::SetTaperDelegate(AAX_ITaperDelegateBase& inTaperDelegate,bool inPreserveValue)
1078{
1079 double normalizeValue = this->GetNormalizedValue ();
1080
1081 AAX_ITaperDelegate<T>* oldDelegate = mTaperDelegate;
1082 mTaperDelegate = ((AAX_ITaperDelegate<T> &) inTaperDelegate).Clone();
1083 delete oldDelegate;
1084
1085 mNeedNotify = true;
1086 if ( inPreserveValue )
1087 this->SetValue ( mValue.Get() );
1088 else this->UpdateNormalizedValue ( normalizeValue );
1089}
1090
1091 template<typename T>
1092 void AAX_CParameter<T>::SetDisplayDelegate(AAX_IDisplayDelegateBase& inDisplayDelegate)
1093{
1094 AAX_IDisplayDelegate<T>* oldDelegate = mDisplayDelegate;
1095 mDisplayDelegate = ((AAX_IDisplayDelegate<T> &)inDisplayDelegate).Clone();
1096 delete oldDelegate;
1097
1098 if (mAutomationDelegate != 0)
1099 mAutomationDelegate->PostCurrentValue(this->Identifier(), this->GetNormalizedValue()); //<DMT> Make sure GUIs are all notified of the change.
1100}
1101
1102 template<typename T>
1103 const AAX_ITaperDelegate<T>* AAX_CParameter<T>::TaperDelegate() const
1104{
1105 return mTaperDelegate;
1106}
1107
1108 template<typename T>
1109 const AAX_IDisplayDelegate<T>* AAX_CParameter<T>::DisplayDelegate() const
1110{
1111 return mDisplayDelegate;
1112}
1113
1114 template<typename T>
1115 bool AAX_CParameter<T>::Automatable() const
1116{
1117 return mAutomatable;
1118}
1119
1120 template<typename T>
1121 void AAX_CParameter<T>::SetAutomationDelegate ( AAX_IAutomationDelegate * iAutomationDelegate )
1122{
1123 //Remove the old automation delegate
1124 if ( mAutomationDelegate )
1125 {
1126 mAutomationDelegate->UnregisterParameter ( this->Identifier() );
1127 }
1128
1129 //Add the new automation delegate, wrapped by the versioning layer.
1130 mAutomationDelegate = iAutomationDelegate;
1131 if ( mAutomationDelegate )
1132 mAutomationDelegate->RegisterParameter ( this->Identifier() );
1133}
1134
1135 template<typename T>
1136 void AAX_CParameter<T>::Touch()
1137{
1138 //<DT> Always send the touch command, even if the control isn't automatable.
1139 if (mAutomationDelegate)
1140 mAutomationDelegate->PostTouchRequest( this->Identifier() );
1141}
1142
1143 template<typename T>
1144 void AAX_CParameter<T>::Release()
1145{
1146 //<DT> Always send the release command, even if the control isn't automatable.
1147 if (mAutomationDelegate)
1148 mAutomationDelegate->PostReleaseRequest( this->Identifier() );
1149}
1150
1151
1153#if 0
1154#pragma mark -
1155#pragma mark AAX_CStatelessParameter
1156#endif
1158
1165 class AAX_CStatelessParameter : public AAX_IParameter
1166{
1167 public:
1168 AAX_CStatelessParameter(AAX_CParamID identifier, const AAX_IString& name, const AAX_IString& inValueString)
1169 : mNames(name)
1170 , mID(identifier)
1171 , mAutomationDelegate(NULL)
1172 , mValueString(inValueString)
1173 {
1174 }
1175
1176 AAX_CStatelessParameter(const AAX_IString& identifier, const AAX_IString& name, const AAX_IString& inValueString)
1177 : mNames(name)
1178 , mID(identifier)
1179 , mAutomationDelegate(NULL)
1180 , mValueString(inValueString)
1181 {
1182 }
1183
1184 AAX_DEFAULT_DTOR_OVERRIDE(AAX_CStatelessParameter);
1185
1186 AAX_IParameterValue* CloneValue() const AAX_OVERRIDE { return NULL; }
1187
1192 AAX_CParamID Identifier() const AAX_OVERRIDE { return mID.CString(); }
1193 void SetName(const AAX_CString& name) AAX_OVERRIDE
1194 {
1195 mNames.SetPrimary(name);
1196 if (mAutomationDelegate) {
1197 mAutomationDelegate->ParameterNameChanged(this->Identifier());
1198 }
1199 }
1200 const AAX_CString& Name() const AAX_OVERRIDE { return mNames.Primary(); }
1201 void AddShortenedName(const AAX_CString& name) AAX_OVERRIDE { mNames.Add(name); }
1202 const AAX_CString& ShortenedName(int32_t iNumCharacters) const AAX_OVERRIDE { return mNames.Get(iNumCharacters); }
1203 void ClearShortenedNames() AAX_OVERRIDE { mNames.Clear(); }
1205
1210 bool Automatable() const AAX_OVERRIDE { return false; }
1211 void SetAutomationDelegate( AAX_IAutomationDelegate * iAutomationDelegate ) AAX_OVERRIDE
1212 {
1213 //Remove the old automation delegate
1214 if ( mAutomationDelegate )
1215 {
1216 mAutomationDelegate->UnregisterParameter ( this->Identifier() );
1217 }
1218
1219 //Add the new automation delegate, wrapped by the versioning layer.
1220 mAutomationDelegate = iAutomationDelegate;
1221 if ( mAutomationDelegate )
1222 mAutomationDelegate->RegisterParameter ( this->Identifier() );
1223 }
1224 void Touch() AAX_OVERRIDE { if (mAutomationDelegate) mAutomationDelegate->PostTouchRequest( this->Identifier() ); }
1225 void Release() AAX_OVERRIDE { if (mAutomationDelegate) mAutomationDelegate->PostReleaseRequest( this->Identifier() ); }
1227
1232 void SetNormalizedValue(double /*newNormalizedValue*/) AAX_OVERRIDE {}
1233 double GetNormalizedValue() const AAX_OVERRIDE { return 0.; }
1234 void SetNormalizedDefaultValue(double /*normalizedDefault*/) AAX_OVERRIDE {}
1235 double GetNormalizedDefaultValue() const AAX_OVERRIDE { return 0.; }
1236 void SetToDefaultValue() AAX_OVERRIDE {}
1237 void SetNumberOfSteps(uint32_t /*numSteps*/) AAX_OVERRIDE {}
1238 uint32_t GetNumberOfSteps() const AAX_OVERRIDE { return 1; }
1239 uint32_t GetStepValue() const AAX_OVERRIDE { return 0; }
1240 double GetNormalizedValueFromStep(uint32_t /*iStep*/) const AAX_OVERRIDE { return 0.; }
1241 uint32_t GetStepValueFromNormalizedValue(double /*normalizedValue*/) const AAX_OVERRIDE { return 0; }
1242 void SetStepValue(uint32_t /*iStep*/) AAX_OVERRIDE {}
1244
1251 bool GetValueString(AAX_CString* valueString) const AAX_OVERRIDE { if (valueString) *valueString = mValueString; return true; }
1252 bool GetValueString(int32_t /*iMaxNumChars*/, AAX_CString* valueString) const AAX_OVERRIDE { return this->GetValueString(valueString); }
1253 bool GetNormalizedValueFromBool(bool /*value*/, double* normalizedValue) const AAX_OVERRIDE { if (normalizedValue) { *normalizedValue = 0.; } return true; }
1254 bool GetNormalizedValueFromInt32(int32_t /*value*/, double* normalizedValue) const AAX_OVERRIDE { if (normalizedValue) { *normalizedValue = 0.; } return true; }
1255 bool GetNormalizedValueFromFloat(float /*value*/, double* normalizedValue) const AAX_OVERRIDE { if (normalizedValue) { *normalizedValue = 0.; } return true; }
1256 bool GetNormalizedValueFromDouble(double /*value*/, double* normalizedValue) const AAX_OVERRIDE { if (normalizedValue) { *normalizedValue = 0.; } return true; }
1257 bool GetNormalizedValueFromString(const AAX_CString& /*valueString*/, double* normalizedValue) const AAX_OVERRIDE { if (normalizedValue) { *normalizedValue = 0.; } return true; }
1258 bool GetBoolFromNormalizedValue(double /*normalizedValue*/, bool* value) const AAX_OVERRIDE { if (value) { *value = false; } return true; }
1259 bool GetInt32FromNormalizedValue(double /*normalizedValue*/, int32_t* /*value*/) const AAX_OVERRIDE { return false; }
1260 bool GetFloatFromNormalizedValue(double /*normalizedValue*/, float* /*value*/) const AAX_OVERRIDE { return false; }
1261 bool GetDoubleFromNormalizedValue(double /*normalizedValue*/, double* /*value*/) const AAX_OVERRIDE { return false; }
1262 bool GetStringFromNormalizedValue(double /*normalizedValue*/, AAX_CString& valueString) const AAX_OVERRIDE { valueString = mValueString; return true; }
1263 bool GetStringFromNormalizedValue(double normalizedValue, int32_t /*iMaxNumChars*/, AAX_CString& valueString) const AAX_OVERRIDE { return this->GetStringFromNormalizedValue(normalizedValue, valueString); }
1264 bool SetValueFromString(const AAX_CString& newValueString) AAX_OVERRIDE { mValueString = newValueString; return true; }
1266
1271 bool GetValueAsBool(bool* value) const AAX_OVERRIDE { if (value) { *value = false; } return true; }
1272 bool GetValueAsInt32(int32_t* /*value*/) const AAX_OVERRIDE { return false; }
1273 bool GetValueAsFloat(float* /*value*/) const AAX_OVERRIDE { return false; }
1274 bool GetValueAsDouble(double* /*value*/) const AAX_OVERRIDE { return false; }
1275 bool GetValueAsString(AAX_IString* /*value*/) const AAX_OVERRIDE { return false; }
1276 bool SetValueWithBool(bool /*value*/) AAX_OVERRIDE { return true; }
1277 bool SetValueWithInt32(int32_t /*value*/) AAX_OVERRIDE { return false; }
1278 bool SetValueWithFloat(float /*value*/) AAX_OVERRIDE { return false; }
1279 bool SetValueWithDouble(double /*value*/) AAX_OVERRIDE { return false; }
1280 bool SetValueWithString(const AAX_IString& value) AAX_OVERRIDE { mValueString = value; return true; }
1282
1283 void SetType( AAX_EParameterType /*iControlType*/ ) AAX_OVERRIDE {};
1284 AAX_EParameterType GetType() const AAX_OVERRIDE { return AAX_eParameterType_Discrete; }
1285
1286 void SetOrientation( AAX_EParameterOrientation /*iOrientation*/ ) AAX_OVERRIDE {}
1287 AAX_EParameterOrientation GetOrientation() const AAX_OVERRIDE { return AAX_eParameterOrientation_Default; }
1288
1289 void SetTaperDelegate ( AAX_ITaperDelegateBase & /*inTaperDelegate*/, bool /*inPreserveValue*/ ) AAX_OVERRIDE {};
1290 void SetDisplayDelegate ( AAX_IDisplayDelegateBase & /*inDisplayDelegate*/ ) AAX_OVERRIDE {};
1291
1296 void UpdateNormalizedValue(double /*newNormalizedValue*/) AAX_OVERRIDE {};
1298
1299 protected:
1300 AAX_CStringAbbreviations mNames;
1301 AAX_CString mID;
1302 AAX_IAutomationDelegate * mAutomationDelegate;
1303 AAX_CString mValueString;
1304};
1305
1306
1307
1308
1309#endif //AAX_CParameter_H
AAX_CString.h
A generic AAX string class with similar functionality to std::string.
AAX_EParameterType
AAX_EParameterType
FIC stuff that I can't include without DAE library dependence.
Definition: AAX_Enums.h:898
AAX_eParameterType_Discrete
@ AAX_eParameterType_Discrete
Definition: AAX_Enums.h:899
AAX_eParameterType_Continuous
@ AAX_eParameterType_Continuous
Definition: AAX_Enums.h:900
AAX_EParameterOrientation
int32_t AAX_EParameterOrientation
Typedef for a bitfield of AAX_EParameterOrientationBits values.
Definition: AAX_Enums.h:931
AAX_eParameterOrientation_Default
@ AAX_eParameterOrientation_Default
Definition: AAX_Enums.h:910
AAX_IDisplayDelegate.h
Defines the display behavior for a parameter.
AAX_ITaperDelegate.h
Defines the taper conversion behavior for a parameter.
AAX_IAutomationDelegate.h
Interface allowing an AAX plug-in to interact with the host's automation system.
AAX_CParamID
const char * AAX_CParamID
Parameter identifier.
Definition: AAX.h:362
kAAX_ParameterIdentifierMaxSize
AAX_CONSTEXPR size_t kAAX_ParameterIdentifierMaxSize
Definition: AAX.h:377
AAX_OVERRIDE
#define AAX_OVERRIDE
override keyword macro
Definition: AAX.h:164
AAX_Assert.h
Declarations for cross-platform AAX_ASSERT, AAX_TRACE and related facilities.
AAX_ASSERT
#define AAX_ASSERT(condition)
Asserts that a condition is true and logs an error if the condition is false.
Definition: AAX_Assert.h:281
AAX_IParameter.h
The base interface for all normalizable plug-in parameters.
AAX_CParameterValue
Concrete implementation of AAX_IParameterValue.
Definition: AAX_CParameter.h:65
AAX_CParameterValue::AAX_DEFAULT_MOVE_OPER
AAX_DEFAULT_MOVE_OPER(AAX_CParameterValue)
AAX_CParameterValue::GetValueAsInt32
bool GetValueAsInt32(int32_t *value) const AAX_OVERRIDE
Retrieves the parameter's value as an int32_t.
Definition: AAX_CParameter.h:168
AAX_CParameterValue::GetValueAsDouble
bool GetValueAsDouble(double *value) const AAX_OVERRIDE
Retrieves the parameter's value as a double.
Definition: AAX_CParameter.h:184
AAX_CParameterValue::GetValueAsString
bool GetValueAsString(AAX_IString *value) const AAX_OVERRIDE
Retrieves the parameter's value as a string.
Definition: AAX_CParameter.h:192
AAX_CParameterValue::Defaults
Defaults
Definition: AAX_CParameter.h:67
AAX_CParameterValue::eParameterDefaultMaxIdentifierLength
@ eParameterDefaultMaxIdentifierLength
Definition: AAX_CParameter.h:69
AAX_CParameterValue::eParameterDefaultMaxIdentifierSize
@ eParameterDefaultMaxIdentifierSize
Definition: AAX_CParameter.h:68
AAX_CParameterValue::Set
void Set(const T &inValue)
Direct access to the template instance's value.
Definition: AAX_CParameter.h:108
AAX_CParameterValue::GetValueAsBool
bool GetValueAsBool(bool *value) const AAX_OVERRIDE
Retrieves the parameter's value as a bool.
Definition: AAX_CParameter.h:159
AAX_CParameterValue::Clone
AAX_IParameterValue * Clone() const AAX_OVERRIDE
Clones the parameter object.
Definition: AAX_CParameter.h:112
AAX_CParameterValue::AAX_DEFAULT_DTOR_OVERRIDE
AAX_DEFAULT_DTOR_OVERRIDE(AAX_CParameterValue)
AAX_CParameterValue::GetValueAsFloat
bool GetValueAsFloat(float *value) const AAX_OVERRIDE
Retrieves the parameter's value as a float.
Definition: AAX_CParameter.h:176
AAX_CParameterValue::AAX_CParameterValue
AAX_CParameterValue(AAX_CParamID identifier)
Constructs an AAX_CParameterValue object.
Definition: AAX_CParameter.h:138
AAX_CParameterValue::AAX_DELETE
AAX_DELETE(AAX_CParameterValue &operator=(const AAX_CParameterValue &))
AAX_CParameterValue::Identifier
AAX_CParamID Identifier() const AAX_OVERRIDE
Returns the parameter's unique identifier.
Definition: AAX_CParameter.h:113
AAX_CParameterValue::AAX_DEFAULT_MOVE_CTOR
AAX_DEFAULT_MOVE_CTOR(AAX_CParameterValue)
AAX_CParameterValue::Get
const T & Get() const
Direct access to the template instance's value.
Definition: AAX_CParameter.h:105
AAX_CParameter
Generic implementation of an AAX_IParameter.
Definition: AAX_CParameter.h:248
AAX_CParameter::SetValueWithString
bool SetValueWithString(const AAX_IString &value) AAX_OVERRIDE
Sets the parameter's value as a string.
Definition: AAX_CParameter.h:803
AAX_CParameter::mValue
AAX_CParameterValue< T > mValue
Definition: AAX_CParameter.h:496
AAX_CParameter::Type
Type
Definition: AAX_CParameter.h:251
AAX_CParameter::eParameterTypeUndefined
@ eParameterTypeUndefined
Definition: AAX_CParameter.h:252
AAX_CParameter::eParameterTypeInt32
@ eParameterTypeInt32
Definition: AAX_CParameter.h:254
AAX_CParameter::eParameterTypeCustom
@ eParameterTypeCustom
Definition: AAX_CParameter.h:256
AAX_CParameter::eParameterTypeFloat
@ eParameterTypeFloat
Definition: AAX_CParameter.h:255
AAX_CParameter::eParameterTypeBool
@ eParameterTypeBool
Definition: AAX_CParameter.h:253
AAX_CParameter::GetBoolFromNormalizedValue
bool GetBoolFromNormalizedValue(double normalizedValue, bool *value) const AAX_OVERRIDE
Converts a normalized parameter value to a bool representing the corresponding real value.
Definition: AAX_CParameter.h:1008
AAX_CParameter::GetType
AAX_EParameterType GetType() const AAX_OVERRIDE
Returns the type of this parameter as an AAX_EParameterType.
Definition: AAX_CParameter.h:917
AAX_CParameter::Name
const AAX_CString & Name() const AAX_OVERRIDE
Returns the parameter's display name.
Definition: AAX_CParameter.h:612
AAX_CParameter::mOrientation
AAX_EParameterOrientation mOrientation
Definition: AAX_CParameter.h:490
AAX_CParameter::mControlType
AAX_EParameterType mControlType
Definition: AAX_CParameter.h:489
AAX_CParameter::mNames
AAX_CStringAbbreviations mNames
Definition: AAX_CParameter.h:486
AAX_CParameter::AAX_DELETE
AAX_DELETE(AAX_CParameter())
AAX_CParameter::mDefaultValue
T mDefaultValue
Definition: AAX_CParameter.h:497
AAX_CParameter::SetValueWithBool
bool SetValueWithBool(bool value) AAX_OVERRIDE
Sets the parameter's value as a bool.
Definition: AAX_CParameter.h:771
AAX_CParameter::mAutomationDelegate
AAX_IAutomationDelegate * mAutomationDelegate
Definition: AAX_CParameter.h:493
AAX_CParameter::AAX_CParameter
AAX_CParameter(AAX_CParamID identifier, const AAX_IString &name, T defaultValue, const AAX_ITaperDelegate< T > &taperDelegate, const AAX_IDisplayDelegate< T > &displayDelegate, bool automatable=false)
Constructs an AAX_CParameter object using the specified taper and display delegates.
Definition: AAX_CParameter.h:507
AAX_CParameter::ShortenedName
const AAX_CString & ShortenedName(int32_t iNumCharacters) const AAX_OVERRIDE
Returns the parameter's shortened display name.
Definition: AAX_CParameter.h:624
AAX_CParameter::mNeedNotify
bool mNeedNotify
Definition: AAX_CParameter.h:494
AAX_CParameter::GetNormalizedValue
double GetNormalizedValue() const AAX_OVERRIDE
Returns the normalized representation of the parameter's current real value.
Definition: AAX_CParameter.h:942
AAX_CParameter::GetDefaultValue
T GetDefaultValue() const
Returns the parameter's default value.
Definition: AAX_CParameter.h:833
AAX_CParameter::GetNormalizedValueFromFloat
bool GetNormalizedValueFromFloat(float value, double *normalizedValue) const AAX_OVERRIDE
Converts a float to a normalized parameter value.
Definition: AAX_CParameter.h:978
AAX_CParameter::mNumSteps
uint32_t mNumSteps
Definition: AAX_CParameter.h:488
AAX_CParameter::GetValueAsFloat
bool GetValueAsFloat(float *value) const AAX_OVERRIDE
Retrieves the parameter's value as a float.
Definition: AAX_CParameter.h:739
AAX_CParameter::SetValue
void SetValue(T newValue)
Initiates a host request to set the parameter's value.
Definition: AAX_CParameter.h:638
AAX_CParameter::~AAX_CParameter
~AAX_CParameter() AAX_OVERRIDE
Virtual destructor used to delete all locally allocated pointers.
Definition: AAX_CParameter.h:579
AAX_CParameter::Release
void Release() AAX_OVERRIDE
Signals the automation system that a control has been released.
Definition: AAX_CParameter.h:1144
AAX_CParameter::AAX_DEFAULT_MOVE_CTOR
AAX_DEFAULT_MOVE_CTOR(AAX_CParameter)
AAX_CParameter::GetNormalizedValueFromBool
bool GetNormalizedValueFromBool(bool value, double *normalizedValue) const AAX_OVERRIDE
Converts a bool to a normalized parameter value.
Definition: AAX_CParameter.h:962
AAX_CParameter::DisplayDelegate
const AAX_IDisplayDelegate< T > * DisplayDelegate() const
Returns a reference to the parameter's display delegate.
Definition: AAX_CParameter.h:1109
AAX_CParameter::Defaults
Defaults
Definition: AAX_CParameter.h:259
AAX_CParameter::eParameterDefaultNumStepsDiscrete
@ eParameterDefaultNumStepsDiscrete
Definition: AAX_CParameter.h:260
AAX_CParameter::eParameterDefaultNumStepsContinuous
@ eParameterDefaultNumStepsContinuous
Definition: AAX_CParameter.h:261
AAX_CParameter::GetNormalizedValueFromInt32
bool GetNormalizedValueFromInt32(int32_t value, double *normalizedValue) const AAX_OVERRIDE
Converts an integer to a normalized parameter value.
Definition: AAX_CParameter.h:970
AAX_CParameter::GetValueAsBool
bool GetValueAsBool(bool *value) const AAX_OVERRIDE
Retrieves the parameter's value as a bool.
Definition: AAX_CParameter.h:727
AAX_CParameter::SetTaperDelegate
void SetTaperDelegate(AAX_ITaperDelegateBase &inTaperDelegate, bool inPreserveValue=true) AAX_OVERRIDE
Sets the parameter's taper delegate.
Definition: AAX_CParameter.h:1077
AAX_CParameter::SetValueWithDouble
bool SetValueWithDouble(double value) AAX_OVERRIDE
Sets the parameter's value as a double.
Definition: AAX_CParameter.h:795
AAX_CParameter::SetDisplayDelegate
void SetDisplayDelegate(AAX_IDisplayDelegateBase &inDisplayDelegate) AAX_OVERRIDE
Sets the parameter's display delegate.
Definition: AAX_CParameter.h:1092
AAX_CParameter::CloneValue
AAX_IParameterValue * CloneValue() const AAX_OVERRIDE
Clone the parameter's value to a new AAX_IParameterValue object.
Definition: AAX_CParameter.h:591
AAX_CParameter::GetValueAsString
bool GetValueAsString(AAX_IString *value) const AAX_OVERRIDE
Retrieves the parameter's value as a string.
Definition: AAX_CParameter.h:751
AAX_CParameter::GetNormalizedValueFromDouble
bool GetNormalizedValueFromDouble(double value, double *normalizedValue) const AAX_OVERRIDE
Converts a double to a normalized parameter value.
Definition: AAX_CParameter.h:986
AAX_CParameter::SetStepValue
void SetStepValue(uint32_t iStep) AAX_OVERRIDE
Returns the current step for the current value of the parameter.
Definition: AAX_CParameter.h:901
AAX_CParameter::GetValue
T GetValue() const
Returns the parameter's value.
Definition: AAX_CParameter.h:720
AAX_CParameter::GetOrientation
AAX_EParameterOrientation GetOrientation() const AAX_OVERRIDE
Returns the orientation of this parameter.
Definition: AAX_CParameter.h:929
AAX_CParameter::UpdateNormalizedValue
void UpdateNormalizedValue(double newNormalizedValue) AAX_OVERRIDE
Sets the parameter's state given a normalized value.
Definition: AAX_CParameter.h:670
AAX_CParameter::AAX_DEFAULT_MOVE_OPER
AAX_DEFAULT_MOVE_OPER(AAX_CParameter)
AAX_CParameter::SetName
void SetName(const AAX_CString &name) AAX_OVERRIDE
Sets the parameter's display name.
Definition: AAX_CParameter.h:603
AAX_CParameter::GetStepValue
uint32_t GetStepValue() const AAX_OVERRIDE
Returns the current step for the current value of the parameter.
Definition: AAX_CParameter.h:861
AAX_CParameter::GetNormalizedDefaultValue
double GetNormalizedDefaultValue() const AAX_OVERRIDE
Returns the normalized representation of the parameter's real default value.
Definition: AAX_CParameter.h:819
AAX_CParameter::SetOrientation
void SetOrientation(AAX_EParameterOrientation iOrientation) AAX_OVERRIDE
Sets the orientation of this parameter.
Definition: AAX_CParameter.h:923
AAX_CParameter::SetToDefaultValue
void SetToDefaultValue() AAX_OVERRIDE
Restores the state of this parameter to its default value.
Definition: AAX_CParameter.h:839
AAX_CParameter::AAX_DELETE
AAX_DELETE(AAX_CParameter(const AAX_CParameter &other))
AAX_CParameter::SetType
void SetType(AAX_EParameterType iControlType) AAX_OVERRIDE
Sets the type of this parameter.
Definition: AAX_CParameter.h:911
AAX_CParameter::SetNormalizedDefaultValue
void SetNormalizedDefaultValue(double normalizedDefault) AAX_OVERRIDE
Sets the parameter's default value using its normalized representation.
Definition: AAX_CParameter.h:812
AAX_CParameter::TaperDelegate
const AAX_ITaperDelegate< T > * TaperDelegate() const
Returns a reference to the parameter's taper delegate.
Definition: AAX_CParameter.h:1103
AAX_CParameter::GetNormalizedValueFromStep
double GetNormalizedValueFromStep(uint32_t iStep) const AAX_OVERRIDE
Returns the normalized value for a given step.
Definition: AAX_CParameter.h:867
AAX_CParameter::AddShortenedName
void AddShortenedName(const AAX_CString &name) AAX_OVERRIDE
Sets the parameter's shortened display name.
Definition: AAX_CParameter.h:618
AAX_CParameter::SetValueFromString
bool SetValueFromString(const AAX_CString &newValueString) AAX_OVERRIDE
Converts a string to a real parameter value and sets the parameter to this value.
Definition: AAX_CParameter.h:1067
AAX_CParameter::GetInt32FromNormalizedValue
bool GetInt32FromNormalizedValue(double normalizedValue, int32_t *value) const AAX_OVERRIDE
Converts a normalized parameter value to an integer representing the corresponding real value.
Definition: AAX_CParameter.h:1017
AAX_CParameter::GetDoubleFromNormalizedValue
bool GetDoubleFromNormalizedValue(double normalizedValue, double *value) const AAX_OVERRIDE
Converts a normalized parameter value to a double representing the corresponding real value.
Definition: AAX_CParameter.h:1033
AAX_CParameter::SetValueWithInt32
bool SetValueWithInt32(int32_t value) AAX_OVERRIDE
Sets the parameter's value as an int32_t.
Definition: AAX_CParameter.h:779
AAX_CParameter::ClearShortenedNames
void ClearShortenedNames() AAX_OVERRIDE
Clears the internal list of shortened display names.
Definition: AAX_CParameter.h:630
AAX_CParameter::mTaperDelegate
AAX_ITaperDelegate< T > * mTaperDelegate
Definition: AAX_CParameter.h:491
AAX_CParameter::SetValueWithFloat
bool SetValueWithFloat(float value) AAX_OVERRIDE
Sets the parameter's value as a float.
Definition: AAX_CParameter.h:787
AAX_CParameter::GetStepValueFromNormalizedValue
uint32_t GetStepValueFromNormalizedValue(double normalizedValue) const AAX_OVERRIDE
Returns the step value for a normalized value of the parameter.
Definition: AAX_CParameter.h:884
AAX_CParameter::SetNumberOfSteps
void SetNumberOfSteps(uint32_t numSteps) AAX_OVERRIDE
Sets the number of discrete steps for this parameter.
Definition: AAX_CParameter.h:845
AAX_CParameter::SetNormalizedValue
void SetNormalizedValue(double newNormalizedValue) AAX_OVERRIDE
Sets a parameter value using it's normalized representation.
Definition: AAX_CParameter.h:935
AAX_CParameter::SetAutomationDelegate
void SetAutomationDelegate(AAX_IAutomationDelegate *iAutomationDelegate) AAX_OVERRIDE
Sets the automation delegate (if one is required)
Definition: AAX_CParameter.h:1121
AAX_CParameter::AAX_DELETE
AAX_DELETE(AAX_CParameter &operator=(const AAX_CParameter &other))
AAX_CParameter::GetValueString
bool GetValueString(AAX_CString *valueString) const AAX_OVERRIDE
Serializes the parameter value into a string.
Definition: AAX_CParameter.h:950
AAX_CParameter::GetStringFromNormalizedValue
bool GetStringFromNormalizedValue(double normalizedValue, AAX_CString &valueString) const AAX_OVERRIDE
Converts a normalized parameter value to a string representing the corresponding real value.
Definition: AAX_CParameter.h:1041
AAX_CParameter::GetFloatFromNormalizedValue
bool GetFloatFromNormalizedValue(double normalizedValue, float *value) const AAX_OVERRIDE
Converts a normalized parameter value to a float representing the corresponding real value.
Definition: AAX_CParameter.h:1025
AAX_CParameter::GetValueAsDouble
bool GetValueAsDouble(double *value) const AAX_OVERRIDE
Retrieves the parameter's value as a double.
Definition: AAX_CParameter.h:745
AAX_CParameter::Automatable
bool Automatable() const AAX_OVERRIDE
Returns true if the parameter is automatable, false if it is not.
Definition: AAX_CParameter.h:1115
AAX_CParameter::Identifier
AAX_CParamID Identifier() const AAX_OVERRIDE
Returns the parameter's unique identifier.
Definition: AAX_CParameter.h:597
AAX_CParameter::GetNormalizedValueFromString
bool GetNormalizedValueFromString(const AAX_CString &valueString, double *normalizedValue) const AAX_OVERRIDE
Converts a given string to a normalized parameter value.
Definition: AAX_CParameter.h:994
AAX_CParameter::mDisplayDelegate
AAX_IDisplayDelegate< T > * mDisplayDelegate
Definition: AAX_CParameter.h:492
AAX_CParameter::SetDefaultValue
void SetDefaultValue(T newDefaultValue)
Set the parameter's default value.
Definition: AAX_CParameter.h:826
AAX_CParameter::mAutomatable
bool mAutomatable
Definition: AAX_CParameter.h:487
AAX_CParameter::GetValueAsInt32
bool GetValueAsInt32(int32_t *value) const AAX_OVERRIDE
Retrieves the parameter's value as an int32_t.
Definition: AAX_CParameter.h:733
AAX_CParameter::Touch
void Touch() AAX_OVERRIDE
Signals the automation system that a control has been touched.
Definition: AAX_CParameter.h:1136
AAX_CParameter::GetNumberOfSteps
uint32_t GetNumberOfSteps() const AAX_OVERRIDE
Returns the number of discrete steps used by the parameter.
Definition: AAX_CParameter.h:855
AAX_CStatelessParameter
A stateless parameter implementation.
Definition: AAX_CParameter.h:1166
AAX_CStatelessParameter::SetValueWithDouble
bool SetValueWithDouble(double) AAX_OVERRIDE
Sets the parameter's value as a double.
Definition: AAX_CParameter.h:1279
AAX_CStatelessParameter::GetStepValueFromNormalizedValue
uint32_t GetStepValueFromNormalizedValue(double) const AAX_OVERRIDE
Returns the step value for a normalized value of the parameter.
Definition: AAX_CParameter.h:1241
AAX_CStatelessParameter::GetValueAsInt32
bool GetValueAsInt32(int32_t *) const AAX_OVERRIDE
Retrieves the parameter's value as an int32_t.
Definition: AAX_CParameter.h:1272
AAX_CStatelessParameter::ClearShortenedNames
void ClearShortenedNames() AAX_OVERRIDE
Clears the internal list of shortened display names.
Definition: AAX_CParameter.h:1203
AAX_CStatelessParameter::GetNormalizedDefaultValue
double GetNormalizedDefaultValue() const AAX_OVERRIDE
Returns the normalized representation of the parameter's real default value.
Definition: AAX_CParameter.h:1235
AAX_CStatelessParameter::GetStringFromNormalizedValue
bool GetStringFromNormalizedValue(double, AAX_CString &valueString) const AAX_OVERRIDE
Converts a normalized parameter value to a string representing the corresponding real value.
Definition: AAX_CParameter.h:1262
AAX_CStatelessParameter::GetNormalizedValue
double GetNormalizedValue() const AAX_OVERRIDE
Returns the normalized representation of the parameter's current real value.
Definition: AAX_CParameter.h:1233
AAX_CStatelessParameter::GetNormalizedValueFromStep
double GetNormalizedValueFromStep(uint32_t) const AAX_OVERRIDE
Returns the normalized value for a given step.
Definition: AAX_CParameter.h:1240
AAX_CStatelessParameter::SetTaperDelegate
void SetTaperDelegate(AAX_ITaperDelegateBase &, bool) AAX_OVERRIDE
Sets the parameter's taper delegate.
Definition: AAX_CParameter.h:1289
AAX_CStatelessParameter::GetBoolFromNormalizedValue
bool GetBoolFromNormalizedValue(double, bool *value) const AAX_OVERRIDE
Converts a normalized parameter value to a bool representing the corresponding real value.
Definition: AAX_CParameter.h:1258
AAX_CStatelessParameter::AddShortenedName
void AddShortenedName(const AAX_CString &name) AAX_OVERRIDE
Sets the parameter's shortened display name.
Definition: AAX_CParameter.h:1201
AAX_CStatelessParameter::GetValueString
bool GetValueString(int32_t, AAX_CString *valueString) const AAX_OVERRIDE
Serializes the parameter value into a string, size hint included.
Definition: AAX_CParameter.h:1252
AAX_CStatelessParameter::GetStepValue
uint32_t GetStepValue() const AAX_OVERRIDE
Returns the current step for the current value of the parameter.
Definition: AAX_CParameter.h:1239
AAX_CStatelessParameter::GetInt32FromNormalizedValue
bool GetInt32FromNormalizedValue(double, int32_t *) const AAX_OVERRIDE
Converts a normalized parameter value to an integer representing the corresponding real value.
Definition: AAX_CParameter.h:1259
AAX_CStatelessParameter::mNames
AAX_CStringAbbreviations mNames
Definition: AAX_CParameter.h:1300
AAX_CStatelessParameter::GetType
AAX_EParameterType GetType() const AAX_OVERRIDE
Returns the type of this parameter as an AAX_EParameterType.
Definition: AAX_CParameter.h:1284
AAX_CStatelessParameter::GetNormalizedValueFromBool
bool GetNormalizedValueFromBool(bool, double *normalizedValue) const AAX_OVERRIDE
Converts a bool to a normalized parameter value.
Definition: AAX_CParameter.h:1253
AAX_CStatelessParameter::UpdateNormalizedValue
void UpdateNormalizedValue(double) AAX_OVERRIDE
Sets the parameter's state given a normalized value.
Definition: AAX_CParameter.h:1296
AAX_CStatelessParameter::SetNumberOfSteps
void SetNumberOfSteps(uint32_t) AAX_OVERRIDE
Sets the number of discrete steps for this parameter.
Definition: AAX_CParameter.h:1237
AAX_CStatelessParameter::SetDisplayDelegate
void SetDisplayDelegate(AAX_IDisplayDelegateBase &) AAX_OVERRIDE
Sets the parameter's display delegate.
Definition: AAX_CParameter.h:1290
AAX_CStatelessParameter::GetOrientation
AAX_EParameterOrientation GetOrientation() const AAX_OVERRIDE
Returns the orientation of this parameter.
Definition: AAX_CParameter.h:1287
AAX_CStatelessParameter::GetNormalizedValueFromInt32
bool GetNormalizedValueFromInt32(int32_t, double *normalizedValue) const AAX_OVERRIDE
Converts an integer to a normalized parameter value.
Definition: AAX_CParameter.h:1254
AAX_CStatelessParameter::Release
void Release() AAX_OVERRIDE
Signals the automation system that a control has been released.
Definition: AAX_CParameter.h:1225
AAX_CStatelessParameter::SetValueWithString
bool SetValueWithString(const AAX_IString &value) AAX_OVERRIDE
Sets the parameter's value as a string.
Definition: AAX_CParameter.h:1280
AAX_CStatelessParameter::AAX_CStatelessParameter
AAX_CStatelessParameter(const AAX_IString &identifier, const AAX_IString &name, const AAX_IString &inValueString)
Definition: AAX_CParameter.h:1176
AAX_CStatelessParameter::GetNormalizedValueFromString
bool GetNormalizedValueFromString(const AAX_CString &, double *normalizedValue) const AAX_OVERRIDE
Converts a given string to a normalized parameter value.
Definition: AAX_CParameter.h:1257
AAX_CStatelessParameter::GetValueAsFloat
bool GetValueAsFloat(float *) const AAX_OVERRIDE
Retrieves the parameter's value as a float.
Definition: AAX_CParameter.h:1273
AAX_CStatelessParameter::GetStringFromNormalizedValue
bool GetStringFromNormalizedValue(double normalizedValue, int32_t, AAX_CString &valueString) const AAX_OVERRIDE
Converts a normalized parameter value to a string representing the corresponding real,...
Definition: AAX_CParameter.h:1263
AAX_CStatelessParameter::Name
const AAX_CString & Name() const AAX_OVERRIDE
Returns the parameter's display name.
Definition: AAX_CParameter.h:1200
AAX_CStatelessParameter::Touch
void Touch() AAX_OVERRIDE
Signals the automation system that a control has been touched.
Definition: AAX_CParameter.h:1224
AAX_CStatelessParameter::SetNormalizedValue
void SetNormalizedValue(double) AAX_OVERRIDE
Sets a parameter value using it's normalized representation.
Definition: AAX_CParameter.h:1232
AAX_CStatelessParameter::SetNormalizedDefaultValue
void SetNormalizedDefaultValue(double) AAX_OVERRIDE
Sets the parameter's default value using its normalized representation.
Definition: AAX_CParameter.h:1234
AAX_CStatelessParameter::SetToDefaultValue
void SetToDefaultValue() AAX_OVERRIDE
Restores the state of this parameter to its default value.
Definition: AAX_CParameter.h:1236
AAX_CStatelessParameter::Automatable
bool Automatable() const AAX_OVERRIDE
Returns true if the parameter is automatable, false if it is not.
Definition: AAX_CParameter.h:1210
AAX_CStatelessParameter::SetValueWithInt32
bool SetValueWithInt32(int32_t) AAX_OVERRIDE
Sets the parameter's value as an int32_t.
Definition: AAX_CParameter.h:1277
AAX_CStatelessParameter::Identifier
AAX_CParamID Identifier() const AAX_OVERRIDE
Returns the parameter's unique identifier.
Definition: AAX_CParameter.h:1192
AAX_CStatelessParameter::GetDoubleFromNormalizedValue
bool GetDoubleFromNormalizedValue(double, double *) const AAX_OVERRIDE
Converts a normalized parameter value to a double representing the corresponding real value.
Definition: AAX_CParameter.h:1261
AAX_CStatelessParameter::GetNormalizedValueFromFloat
bool GetNormalizedValueFromFloat(float, double *normalizedValue) const AAX_OVERRIDE
Converts a float to a normalized parameter value.
Definition: AAX_CParameter.h:1255
AAX_CStatelessParameter::SetValueWithBool
bool SetValueWithBool(bool) AAX_OVERRIDE
Sets the parameter's value as a bool.
Definition: AAX_CParameter.h:1276
AAX_CStatelessParameter::mID
AAX_CString mID
Definition: AAX_CParameter.h:1301
AAX_CStatelessParameter::AAX_CStatelessParameter
AAX_CStatelessParameter(AAX_CParamID identifier, const AAX_IString &name, const AAX_IString &inValueString)
Definition: AAX_CParameter.h:1168
AAX_CStatelessParameter::SetValueWithFloat
bool SetValueWithFloat(float) AAX_OVERRIDE
Sets the parameter's value as a float.
Definition: AAX_CParameter.h:1278
AAX_CStatelessParameter::SetValueFromString
bool SetValueFromString(const AAX_CString &newValueString) AAX_OVERRIDE
Converts a string to a real parameter value and sets the parameter to this value.
Definition: AAX_CParameter.h:1264
AAX_CStatelessParameter::GetNormalizedValueFromDouble
bool GetNormalizedValueFromDouble(double, double *normalizedValue) const AAX_OVERRIDE
Converts a double to a normalized parameter value.
Definition: AAX_CParameter.h:1256
AAX_CStatelessParameter::GetValueAsString
bool GetValueAsString(AAX_IString *) const AAX_OVERRIDE
Retrieves the parameter's value as a string.
Definition: AAX_CParameter.h:1275
AAX_CStatelessParameter::SetAutomationDelegate
void SetAutomationDelegate(AAX_IAutomationDelegate *iAutomationDelegate) AAX_OVERRIDE
Sets the automation delegate (if one is required)
Definition: AAX_CParameter.h:1211
AAX_CStatelessParameter::GetValueString
bool GetValueString(AAX_CString *valueString) const AAX_OVERRIDE
Serializes the parameter value into a string.
Definition: AAX_CParameter.h:1251
AAX_CStatelessParameter::SetStepValue
void SetStepValue(uint32_t) AAX_OVERRIDE
Returns the current step for the current value of the parameter.
Definition: AAX_CParameter.h:1242
AAX_CStatelessParameter::SetType
void SetType(AAX_EParameterType) AAX_OVERRIDE
Sets the type of this parameter.
Definition: AAX_CParameter.h:1283
AAX_CStatelessParameter::mValueString
AAX_CString mValueString
Definition: AAX_CParameter.h:1303
AAX_CStatelessParameter::SetName
void SetName(const AAX_CString &name) AAX_OVERRIDE
Sets the parameter's display name.
Definition: AAX_CParameter.h:1193
AAX_CStatelessParameter::GetFloatFromNormalizedValue
bool GetFloatFromNormalizedValue(double, float *) const AAX_OVERRIDE
Converts a normalized parameter value to a float representing the corresponding real value.
Definition: AAX_CParameter.h:1260
AAX_CStatelessParameter::ShortenedName
const AAX_CString & ShortenedName(int32_t iNumCharacters) const AAX_OVERRIDE
Returns the parameter's shortened display name.
Definition: AAX_CParameter.h:1202
AAX_CStatelessParameter::GetValueAsBool
bool GetValueAsBool(bool *value) const AAX_OVERRIDE
Retrieves the parameter's value as a bool.
Definition: AAX_CParameter.h:1271
AAX_CStatelessParameter::mAutomationDelegate
AAX_IAutomationDelegate * mAutomationDelegate
Definition: AAX_CParameter.h:1302
AAX_CStatelessParameter::AAX_DEFAULT_DTOR_OVERRIDE
AAX_DEFAULT_DTOR_OVERRIDE(AAX_CStatelessParameter)
AAX_CStatelessParameter::GetNumberOfSteps
uint32_t GetNumberOfSteps() const AAX_OVERRIDE
Returns the number of discrete steps used by the parameter.
Definition: AAX_CParameter.h:1238
AAX_CStatelessParameter::SetOrientation
void SetOrientation(AAX_EParameterOrientation) AAX_OVERRIDE
Sets the orientation of this parameter.
Definition: AAX_CParameter.h:1286
AAX_CStatelessParameter::CloneValue
AAX_IParameterValue * CloneValue() const AAX_OVERRIDE
Clone the parameter's value to a new AAX_IParameterValue object.
Definition: AAX_CParameter.h:1186
AAX_CStatelessParameter::GetValueAsDouble
bool GetValueAsDouble(double *) const AAX_OVERRIDE
Retrieves the parameter's value as a double.
Definition: AAX_CParameter.h:1274
AAX_CString
A generic AAX string class with similar functionality to std::string
Definition: AAX_CString.h:57
AAX_CString::CString
const char * CString() const
AAX_CString::Get
const char * Get() const AAX_OVERRIDE
AAX_CStringAbbreviations
Helper class to store a collection of name abbreviations.
Definition: AAX_CString.h:186
AAX_CStringAbbreviations::Clear
void Clear()
Definition: AAX_CString.h:220
AAX_CStringAbbreviations::Add
void Add(const AAX_CString &inAbbreviation)
Definition: AAX_CString.h:197
AAX_CStringAbbreviations::Primary
const AAX_CString & Primary() const
Definition: AAX_CString.h:195
AAX_CStringAbbreviations::Get
const AAX_CString & Get(int32_t inNumCharacters) const
Definition: AAX_CString.h:203
AAX_CStringAbbreviations::SetPrimary
void SetPrimary(const AAX_CString &inPrimary)
Definition: AAX_CString.h:194
AAX_IAutomationDelegate
Interface allowing an AAX plug-in to interact with the host's event system.
Definition: AAX_IAutomationDelegate.h:57
AAX_IAutomationDelegate::PostTouchRequest
virtual AAX_Result PostTouchRequest(AAX_CParamID iParameterID)=0
AAX_IAutomationDelegate::RegisterParameter
virtual AAX_Result RegisterParameter(AAX_CParamID iParameterID)=0
AAX_IAutomationDelegate::PostReleaseRequest
virtual AAX_Result PostReleaseRequest(AAX_CParamID iParameterID)=0
AAX_IAutomationDelegate::UnregisterParameter
virtual AAX_Result UnregisterParameter(AAX_CParamID iParameterID)=0
AAX_IAutomationDelegate::ParameterNameChanged
virtual AAX_Result ParameterNameChanged(AAX_CParamID iParameterID)=0
AAX_IDisplayDelegateBase
Defines the display behavior for a parameter.
Definition: AAX_IDisplayDelegate.h:63
AAX_IDisplayDelegate
Definition: AAX_IDisplayDelegate.h:79
AAX_IDisplayDelegate::Clone
virtual AAX_IDisplayDelegate * Clone() const =0
Constructs and returns a copy of the display delegate.
AAX_IParameterValue
An abstract interface representing a parameter value of arbitrary type.
Definition: AAX_IParameter.h:55
AAX_IParameter
The base interface for all normalizable plug-in parameters.
Definition: AAX_IParameter.h:150
AAX_IString
A simple string container that can be passed across a binary boundary. This class,...
Definition: AAX_IString.h:51
AAX_ITaperDelegateBase
Defines the taper conversion behavior for a parameter.
Definition: AAX_ITaperDelegate.h:83
AAX_ITaperDelegate
Definition: AAX_ITaperDelegate.h:99
AAX_ITaperDelegate::Clone
virtual AAX_ITaperDelegate * Clone() const =0
Constructs and returns a copy of the taper delegate.