DISTRHO Plugin Framework
|
#include <DistrhoUI.hpp>
Public Member Functions | |
UI (uint width=0, uint height=0) | |
virtual | ~UI () |
uint | getBackgroundColor () const noexcept |
uint | getForegroundColor () const noexcept |
double | getSampleRate () const noexcept |
void | editParameter (uint32_t index, bool started) |
void | setParameterValue (uint32_t index, float value) |
void | setState (const char *key, const char *value) |
void | sendNote (uint8_t channel, uint8_t note, uint8_t velocity) |
void * | getPluginInstancePointer () const noexcept |
Static Public Member Functions | |
static const char * | getNextBundlePath () noexcept |
static double | getNextScaleFactor () noexcept |
static uintptr_t | getNextWindowId () noexcept |
Protected Member Functions | |
virtual void | parameterChanged (uint32_t index, float value)=0 |
virtual void | programLoaded (uint32_t index)=0 |
virtual void | stateChanged (const char *key, const char *value)=0 |
virtual void | sampleRateChanged (double newSampleRate) |
Friends | |
class | UIExporter |
class | UIExporterWindow |
DPF UI class from where UI instances are created.
UI::UI | ( | uint | width = 0 , |
uint | height = 0 |
||
) |
|
virtual |
Destructor.
|
noexcept |
Get the color used for UI background (i.e. window color) in RGBA format. Returns 0 by default, in case of error or lack of host support.
The following example code can be use to extract individual colors:
|
noexcept |
Get the color used for UI foreground (i.e. text color) in RGBA format. Returns 0xffffffff by default, in case of error or lack of host support.
The following example code can be use to extract individual colors:
|
noexcept |
Get the current sample rate used in plugin processing.
void UI::editParameter | ( | uint32_t | index, |
bool | started | ||
) |
editParameter.
Touch/pressed-down event. Lets the host know the user is tweaking a parameter. Required in some hosts to record automation.
void UI::setParameterValue | ( | uint32_t | index, |
float | value | ||
) |
setParameterValue.
Change a parameter value in the Plugin.
void UI::setState | ( | const char * | key, |
const char * | value | ||
) |
setState. @TODO Document this.
void UI::sendNote | ( | uint8_t | channel, |
uint8_t | note, | ||
uint8_t | velocity | ||
) |
sendNote. @TODO Document this.
|
noexcept |
getPluginInstancePointer. @TODO Document this.
|
staticnoexcept |
Get the bundle path that will be used for the next UI.
|
staticnoexcept |
Get the scale factor that will be used for the next UI.
|
staticnoexcept |
Get the Window Id that will be used for the next created window.
|
protectedpure virtual |
A parameter has changed on the plugin side.
This is called by the host to inform the UI about parameter changes.
|
protectedpure virtual |
A program has been loaded on the plugin side.
This is called by the host to inform the UI about program changes.
|
protectedpure virtual |
A state has changed on the plugin side.
This is called by the host to inform the UI about state changes.
|
protectedvirtual |
Optional callback to inform the UI about a sample rate change on the plugin side.