SPAOP
|
The SPAOP-plugin's processor class. More...
#include <PluginProcessor.h>
Public Member Functions | |
SpaopAudioProcessor () | |
Constructor. More... | |
~SpaopAudioProcessor () | |
Destructor. More... | |
void | prepareToPlay (double sampleRate, int samplesPerBlock) |
void | releaseResources () |
void | processBlock (AudioSampleBuffer &buffer, MidiBuffer &midiMessages) |
AudioProcessorEditor * | createEditor () |
bool | hasEditor () const |
const String | getName () const |
int | getNumParameters () |
Returns the number of automatable parameters of this plugin. More... | |
float | getParameter (int index) |
Forwards the call to the wonder::Source::getParameter method of the source controlled by this plugin. More... | |
void | setParameter (int index, float newValue) |
Forwards the call to the wonder::SourceController::setParameterAndSendChange. More... | |
float | getParameterByText (int parameterIndex, const String ¶meterText) |
Forwards the call to the wonder::Source::getParameterByText method of the source controlled by this plugin. More... | |
const String | getParameterName (int index) |
Forwards the call to the wonder::Source::getParameterName method of the source controlled by this plugin. More... | |
const String | getParameterText (int index) |
Forwards the call to the wonder::Source::getParameterText method of the source controlled by this plugin. More... | |
const String | getParameterTextByValue (int index, float value) |
Forwards the call to the wonder::Source::getParameterTextByValue method of the source controlled by this plugin. More... | |
int | getParameterNumSteps (int index) |
float | getParameterDefaultValue (int index) |
Forwards the call to wonder::Source::getParameterDefaultValue. More... | |
const String | getInputChannelName (int channelIndex) const |
const String | getOutputChannelName (int channelIndex) const |
bool | isInputChannelStereoPair (int index) const |
bool | isOutputChannelStereoPair (int index) const |
bool | acceptsMidi () const |
bool | producesMidi () const |
bool | silenceInProducesSilenceOut () const |
double | getTailLengthSeconds () const |
int | getNumPrograms () |
Returns 0. More... | |
int | getCurrentProgram () |
Returns 0. More... | |
void | setCurrentProgram (int index) |
Does nothing. More... | |
const String | getProgramName (int index) |
Returns an empty juce::String. More... | |
void | changeProgramName (int index, const String &newName) |
Does nothing. More... | |
void | getStateInformation (MemoryBlock &destData) |
Stores the current state of the plugin (including the state of the source controlled by this plugin) into the MemoryBlock destData. More... | |
void | setStateInformation (const void *data, int sizeInBytes) |
Retores the a state of the plugin (including the state of the source controlled by this plugin) from a memory block (as stored with getStateInformation). More... | |
void | setCoordinates (float normalizedX, float normalizedY) |
Sets the coordinates, sending the corresponding OSC-message. More... | |
void | setCoordinatesNotifyingHost (float normalizedX, float normalizedY) |
Sets the coordinates, notifying both the host and the OSC-messaging. More... | |
void | timerCallback () |
Callback from the timer. More... | |
wonder::SourceController * | getSourceController () const |
Returns a pointer to the wonder::SourceController object that contains the main logic and the communication threads of this plugin. More... | |
float | getZoomFactor () const |
Returns the zoom factor for the GUI. More... | |
void | setZoomFactor (float zoomFactor) |
Sets the zoom factor for the GUI. More... | |
bool | showOtherSources () const |
Returns true if the GUI shall show all active sources. More... | |
void | setShowOtherSources (bool showOtherSources) |
Set the GUI's showOtherSources parameter (As this parameters shall be restorable via getStateInformation and setStateInformation, it needs to be stored within this class.) More... | |
bool | showNames () const |
Returns true if the GUI shall the sources' names. More... | |
void | setShowNames (bool showNames) |
Set the GUI's showNames parameter (As this parameters shall be restorable via getStateInformation and setStateInformation, it needs to be stored within this class.) More... | |
bool | setCWonderAddress (const std::string &ip, const std::string &port) |
Sets the address where outgoing OSC messages will be sent in "linked to
WONDER" mode will be sent (i.e. More... | |
The SPAOP-plugin's processor class.
Initializes its wonder::SourceController instance and works as the interface to the host software.
SpaopAudioProcessor::SpaopAudioProcessor | ( | ) |
Constructor.
SpaopAudioProcessor::~SpaopAudioProcessor | ( | ) |
Destructor.
bool SpaopAudioProcessor::acceptsMidi | ( | ) | const |
void SpaopAudioProcessor::changeProgramName | ( | int | index, |
const String & | newName | ||
) |
Does nothing.
AudioProcessorEditor * SpaopAudioProcessor::createEditor | ( | ) |
int SpaopAudioProcessor::getCurrentProgram | ( | ) |
Returns 0.
const String SpaopAudioProcessor::getInputChannelName | ( | int | channelIndex | ) | const |
const String SpaopAudioProcessor::getName | ( | ) | const |
int SpaopAudioProcessor::getNumParameters | ( | ) |
Returns the number of automatable parameters of this plugin.
This equals the value of wonder::Source::totalNumParams.
int SpaopAudioProcessor::getNumPrograms | ( | ) |
Returns 0.
const String SpaopAudioProcessor::getOutputChannelName | ( | int | channelIndex | ) | const |
float SpaopAudioProcessor::getParameter | ( | int | index | ) |
Forwards the call to the wonder::Source::getParameter method of the source controlled by this plugin.
float SpaopAudioProcessor::getParameterByText | ( | int | parameterIndex, |
const String & | parameterText | ||
) |
Forwards the call to the wonder::Source::getParameterByText method of the source controlled by this plugin.
This overrides a method of juce::AudioProcessor that is not contained in the official version of JUCE but only in the fork of JUCE that was created for SPAOP.
float SpaopAudioProcessor::getParameterDefaultValue | ( | int | index | ) |
Forwards the call to wonder::Source::getParameterDefaultValue.
const String SpaopAudioProcessor::getParameterName | ( | int | index | ) |
Forwards the call to the wonder::Source::getParameterName method of the source controlled by this plugin.
int SpaopAudioProcessor::getParameterNumSteps | ( | int | index | ) |
const String SpaopAudioProcessor::getParameterText | ( | int | index | ) |
Forwards the call to the wonder::Source::getParameterText method of the source controlled by this plugin.
const String SpaopAudioProcessor::getParameterTextByValue | ( | int | index, |
float | value | ||
) |
Forwards the call to the wonder::Source::getParameterTextByValue method of the source controlled by this plugin.
This overrides a method of juce::AudioProcessor that is not contained in the official version of JUCE but only in the fork of JUCE that was created for SPAOP.
const String SpaopAudioProcessor::getProgramName | ( | int | index | ) |
Returns an empty juce::String.
wonder::SourceController * SpaopAudioProcessor::getSourceController | ( | ) | const |
Returns a pointer to the wonder::SourceController object that contains the main logic and the communication threads of this plugin.
void SpaopAudioProcessor::getStateInformation | ( | MemoryBlock & | destData | ) |
Stores the current state of the plugin (including the state of the source controlled by this plugin) into the MemoryBlock destData.
All attributes are stored in XML format.
double SpaopAudioProcessor::getTailLengthSeconds | ( | ) | const |
float SpaopAudioProcessor::getZoomFactor | ( | ) | const |
Returns the zoom factor for the GUI.
(As this parameters shall be restorable via getStateInformation and setStateInformation, it needs to be stored within this class.(
bool SpaopAudioProcessor::hasEditor | ( | ) | const |
bool SpaopAudioProcessor::isInputChannelStereoPair | ( | int | index | ) | const |
bool SpaopAudioProcessor::isOutputChannelStereoPair | ( | int | index | ) | const |
void SpaopAudioProcessor::prepareToPlay | ( | double | sampleRate, |
int | samplesPerBlock | ||
) |
void SpaopAudioProcessor::processBlock | ( | AudioSampleBuffer & | buffer, |
MidiBuffer & | midiMessages | ||
) |
bool SpaopAudioProcessor::producesMidi | ( | ) | const |
void SpaopAudioProcessor::releaseResources | ( | ) |
void SpaopAudioProcessor::setCoordinates | ( | float | normalizedX, |
float | normalizedY | ||
) |
Sets the coordinates, sending the corresponding OSC-message.
For coordinate changes, this is to be prefered since it will result in only one OSC message (while two separate calls to setParameterNotifyingHost might result in two messages).
normalizedX | The new value for the x-coordinate, normalized within [0.0 , 1.0]. |
normalizedY | The new value for the y-coordinate, normalized within [0.0 , 1.0]. |
void SpaopAudioProcessor::setCoordinatesNotifyingHost | ( | float | normalizedX, |
float | normalizedY | ||
) |
Sets the coordinates, notifying both the host and the OSC-messaging.
For coordinate changes, this is to be prefered since it will result in only one OSC message (while two separate calls to setParameterNotifyingHost might result in two messages).
normalizedX | The new value for the x-coordinate, normalized within [0.0 , 1.0]. |
normalizedY | The new value for the y-coordinate, normalized within [0.0 , 1.0]. |
void SpaopAudioProcessor::setCurrentProgram | ( | int | index | ) |
Does nothing.
bool SpaopAudioProcessor::setCWonderAddress | ( | const std::string & | ip, |
const std::string & | port | ||
) |
Sets the address where outgoing OSC messages will be sent in "linked to WONDER" mode will be sent (i.e.
the address of cWONDER). (Internally, the call is passed to wonder::SourceController::setCWonderAddress.)
ip | A valid (IPv4) ip string. |
port | A valid port number between 1024 and 65535. |
void SpaopAudioProcessor::setParameter | ( | int | index, |
float | newValue | ||
) |
Forwards the call to the wonder::SourceController::setParameterAndSendChange.
void SpaopAudioProcessor::setShowNames | ( | bool | showNames | ) |
Set the GUI's showNames parameter (As this parameters shall be restorable via getStateInformation and setStateInformation, it needs to be stored within this class.)
showNames | true if the GUI shall show the sources' names. |
void SpaopAudioProcessor::setShowOtherSources | ( | bool | showOtherSources | ) |
Set the GUI's showOtherSources parameter (As this parameters shall be restorable via getStateInformation and setStateInformation, it needs to be stored within this class.)
showOtherSources | true if the GUI shall show all active sources. |
void SpaopAudioProcessor::setStateInformation | ( | const void * | data, |
int | sizeInBytes | ||
) |
Retores the a state of the plugin (including the state of the source controlled by this plugin) from a memory block (as stored with getStateInformation).
void SpaopAudioProcessor::setZoomFactor | ( | float | zoomFactor | ) |
Sets the zoom factor for the GUI.
(As this parameters shall be restorable via getStateInformation and setStateInformation, it needs to be stored within this class.)
zoomFactor | The zoom factor for the GUI. |
bool SpaopAudioProcessor::showNames | ( | ) | const |
Returns true if the GUI shall the sources' names.
(As this parameters shall be restorable via getStateInformation and setStateInformation, it needs to be stored within this class.)
bool SpaopAudioProcessor::showOtherSources | ( | ) | const |
Returns true if the GUI shall show all active sources.
(As this parameters shall be restorable via getStateInformation and setStateInformation, it needs to be stored within this class.)
bool SpaopAudioProcessor::silenceInProducesSilenceOut | ( | ) | const |
void SpaopAudioProcessor::timerCallback | ( | ) |
Callback from the timer.
If the timer runs out, we did not receive a ping message for the incoming "visual" stream which means: the connections is lost.