openshot-audio  0.1.2
juce_AudioProcessorParameter.h
Go to the documentation of this file.
1 /*
2  ==============================================================================
3 
4  This file is part of the JUCE library.
5  Copyright (c) 2015 - ROLI Ltd.
6 
7  Permission is granted to use this software under the terms of either:
8  a) the GPL v2 (or any later version)
9  b) the Affero GPL v3
10 
11  Details of these licenses can be found at: www.gnu.org/licenses
12 
13  JUCE is distributed in the hope that it will be useful, but WITHOUT ANY
14  WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
15  A PARTICULAR PURPOSE. See the GNU General Public License for more details.
16 
17  ------------------------------------------------------------------------------
18 
19  To release a closed-source product which uses JUCE, commercial licenses are
20  available: visit www.juce.com for more information.
21 
22  ==============================================================================
23 */
24 
25 #ifndef JUCE_AUDIOPROCESSORPARAMETER_H_INCLUDED
26 #define JUCE_AUDIOPROCESSORPARAMETER_H_INCLUDED
27 
28 
29 //==============================================================================
36 {
37 public:
39 
41  virtual ~AudioProcessorParameter();
42 
51  virtual float getValue() const = 0;
52 
66  virtual void setValue (float newValue) = 0;
67 
78  void setValueNotifyingHost (float newValue);
79 
86  void beginChangeGesture();
87 
93  void endChangeGesture();
94 
96  virtual float getDefaultValue() const = 0;
97 
101  virtual String getName (int maximumStringLength) const = 0;
102 
106  virtual String getLabel() const = 0;
107 
116  virtual int getNumSteps() const;
117 
123  virtual String getText (float value, int /*maximumStringLength*/) const;
124 
126  virtual float getValueForText (const String& text) const = 0;
127 
132  virtual bool isOrientationInverted() const;
133 
137  virtual bool isAutomatable() const;
138 
144  virtual bool isMetaParameter() const;
145 
147  int getParameterIndex() const noexcept { return parameterIndex; }
148 
149 private:
150  friend class AudioProcessor;
151  AudioProcessor* processor;
152  int parameterIndex;
153 
155 };
156 
157 
158 #endif // JUCE_AUDIOPROCESSORPARAMETER_H_INCLUDED
#define noexcept
Definition: juce_CompilerSupport.h:141
Definition: juce_String.h:43
#define JUCE_API
Definition: juce_StandardHeader.h:139
#define JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR(className)
Definition: juce_PlatformDefs.h:198
int getParameterIndex() const noexcept
Definition: juce_AudioProcessorParameter.h:147
Definition: juce_AudioProcessor.h:43
Definition: juce_AudioProcessorParameter.h:35