The grand central station of HISE. More...
Classes | |
class | EventIdHandler |
This class will iterate over incoming MIDI messages, and transform them into HiseEvents with a succesive index for note-on / note-off messages. More... | |
struct | GlobalAsyncModuleHandler |
A class that handles the asynchronous adding / removal of Processor objects to the signal path. More... | |
class | KillStateHandler |
Handles the voice killing when a longer task is about to start. More... | |
class | LockFreeDispatcher |
This class is a dispatcher for methods that are being called by either the message thread or the sample loading thread. More... | |
class | MacroManager |
Contains methods for handling macros, MIDI automation and MPE gestures. More... | |
class | SampleManager |
Contains all methods related to sample management. More... | |
class | UserPresetHandler |
The handler class for user presets in HISE. More... | |
Public Member Functions | |
void | addTempoListener (TempoListener *t) |
adds a TempoListener to the main controller that will receive a callback whenever the host changes the tempo. More... | |
void | allNotesOff (bool resetSoftBypassState=false) |
Call this if you want all voices to stop. More... | |
void | beginParameterChangeGesture (int index) |
same as AudioProcessor::beginParameterGesture(). More... | |
void | compileAllScripts () |
Compiles all scripts in the main synth chain. | |
void | endParameterChangeGesture (int index) |
same as AudioProcessor::beginParameterGesture(). More... | |
double | getBpm () const noexcept |
returns the tempo as bpm. More... | |
float | getCpuUsage () const |
Returns the time that the plugin spends in its processBlock method. More... | |
double | getGlobalPitchFactor () const |
This returns the global pitch factor. More... | |
double | getGlobalPitchFactorSemiTones () const |
This returns the global pitch factor as semitones. More... | |
virtual ModulatorSynthChain * | getMainSynthChain ()=0 |
this must be overwritten by the derived class and return the master synth chain. More... | |
int | getNumActiveVoices () const |
Returns the amount of playing voices. More... | |
double | getUptime () const noexcept |
Returns the uptime in seconds. More... | |
bool | isInitialised () const noexcept |
This returns always true after the processor was initialised. More... | |
void | removeTempoListener (TempoListener *t) |
removes a TempoListener. More... | |
void | setGlobalPitchFactor (double pitchFactorInSemiTones) |
This sets the global pitch factor. More... | |
void | setPluginParameter (int index, float newValue) |
sets the plugin parameter to the new Value. More... | |
void | skin (Component &c) |
skins the given component (applies the global look and feel to it). More... | |
Public Member Functions inherited from GlobalScriptCompileBroadcaster | |
void | addScriptListener (GlobalScriptCompileListener *listener, bool insertAtBeginning=false) |
Adds a ScriptListener. More... | |
void | sendScriptCompileMessage (JavascriptProcessor *processorThatWasCompiled) |
This sends a synchronous message to all registered listeners. More... | |
Static Public Member Functions | |
static Processor * | createProcessor (FactoryType *FactoryTypeToUse, const Identifier &typeName, const String &id) |
Create a new processor and returns it. More... | |
Protected Member Functions | |
void | checkAllNotesOff () |
Checks if a connected object called allNotesOff() and replaces the content of the supplied MidiBuffer with a allNoteOff event. More... | |
void | setBpm (double bpm_) |
sets the new BPM and sends a message to all registered tempo listeners if the tempo changed. More... | |
void | startCpuBenchmark (int bufferSize) |
Add this at the beginning of your processBlock() method to enable CPU measurement. | |
void | stopCpuBenchmark () |
Add this at the end of your processBlock() method to enable CPU measurement. | |
The grand central station of HISE.
The MainController class represents the instance of a HISE project and can be used to access quasi-global data / methods.
It is divided into multiple sub-classes which encapsulate different logic in order to bring some order into the enormous task of handling everything:
Implementations of this class are also derived by the juce::AudioProcessor and some other helper classes. Check out the hise::FrontendProcessor class for actual usage in a C++ HISE project.
Most classes just want a reference to the MainController instance. If you want to use it in your C++ classes, I recommend subclassing it from ControlledObject, which exists for this sole purpose.
void addTempoListener | ( | TempoListener * | t | ) |
adds a TempoListener to the main controller that will receive a callback whenever the host changes the tempo.
void allNotesOff | ( | bool | resetSoftBypassState = false | ) |
Call this if you want all voices to stop.
void beginParameterChangeGesture | ( | int | index | ) |
same as AudioProcessor::beginParameterGesture().
|
inlineprotected |
Checks if a connected object called allNotesOff() and replaces the content of the supplied MidiBuffer with a allNoteOff event.
|
static |
Create a new processor and returns it.
You have to supply a Chain that the Processor will be added to.
The function is static (it will get the MainController() instance from the FactoryType).
FactoryType | this is used to create the processor and connect it to the MainController. |
typeName | the identifier string of the processor that should be created. |
id | the name of the processor to be created. |
void endParameterChangeGesture | ( | int | index | ) |
same as AudioProcessor::beginParameterGesture().
|
inlinenoexcept |
returns the tempo as bpm.
|
inline |
Returns the time that the plugin spends in its processBlock method.
|
inline |
This returns the global pitch factor.
Use this in your startVoice method and multiplicate it with your angleDelta.
|
inline |
This returns the global pitch factor as semitones.
This can be used for displaying / saving purposes.
|
pure virtual |
this must be overwritten by the derived class and return the master synth chain.
int getNumActiveVoices | ( | ) | const |
Returns the amount of playing voices.
|
inlinenoexcept |
Returns the uptime in seconds.
|
noexcept |
This returns always true after the processor was initialised.
void removeTempoListener | ( | TempoListener * | t | ) |
removes a TempoListener.
|
protected |
sets the new BPM and sends a message to all registered tempo listeners if the tempo changed.
|
inline |
This sets the global pitch factor.
void setPluginParameter | ( | int | index, |
float | newValue | ||
) |
sets the plugin parameter to the new Value.
void skin | ( | Component & | c | ) |
skins the given component (applies the global look and feel to it).