|
JUCE-7.0.12-0-g4f43011b96 JUCE-7.0.12-0-g4f43011b96
JUCE — C++ application framework with suport for VST, VST3, LV2 audio plug-ins
« « « Anklang Documentation |
Advanced implementation (support IUnitInfo) for a VST 3 edit controller. More...
#include "vsteditcontroller.h"
Public Member Functions | |
| tresult PLUGIN_API | terminate () SMTG_OVERRIDE |
| This function is called before the plug-in is unloaded and can be used for cleanups. | |
| bool | addUnit (Unit *unit) |
| Adds a given unit. | |
| bool | addProgramList (ProgramList *list) |
| Adds a given program list. | |
| ProgramList * | getProgramList (ProgramListID listId) const |
| Returns the ProgramList associated to a given listId. | |
| tresult | notifyProgramListChange (ProgramListID listId, int32 programIndex=kAllProgramInvalid) |
| Notifies the host about program list changes. | |
| int32 PLUGIN_API | getUnitCount () SMTG_OVERRIDE |
| Returns the flat count of units. | |
| tresult PLUGIN_API | getUnitInfo (int32 unitIndex, UnitInfo &info) SMTG_OVERRIDE |
| Gets UnitInfo for a given index in the flat list of unit. | |
| int32 PLUGIN_API | getProgramListCount () SMTG_OVERRIDE |
| Component intern program structure. | |
| tresult PLUGIN_API | getProgramListInfo (int32 listIndex, ProgramListInfo &info) SMTG_OVERRIDE |
| Gets for a given index the Program List Info. | |
| tresult PLUGIN_API | getProgramName (ProgramListID listId, int32 programIndex, String128 name) SMTG_OVERRIDE |
| Gets for a given program list ID and program index its program name. | |
| tresult PLUGIN_API | getProgramInfo (ProgramListID listId, int32 programIndex, CString attributeId, String128 attributeValue) SMTG_OVERRIDE |
| Gets for a given program list ID, program index and attributeId the associated attribute value. | |
| tresult PLUGIN_API | hasProgramPitchNames (ProgramListID listId, int32 programIndex) SMTG_OVERRIDE |
| Returns kResultTrue if the given program index of a given program list ID supports PitchNames. | |
| tresult PLUGIN_API | getProgramPitchName (ProgramListID listId, int32 programIndex, int16 midiPitch, String128 name) SMTG_OVERRIDE |
| Gets the PitchName for a given program list ID, program index and pitch. | |
| virtual tresult | setProgramName (ProgramListID listId, int32 programIndex, const String128 name) |
| UnitID PLUGIN_API | getSelectedUnit () SMTG_OVERRIDE |
| Gets the current selected unit. | |
| tresult PLUGIN_API | selectUnit (UnitID unitId) SMTG_OVERRIDE |
| Sets a new selected unit. | |
| tresult PLUGIN_API | getUnitByBus (MediaType, BusDirection, int32, int32, UnitID &) SMTG_OVERRIDE |
| Gets the according unit if there is an unambiguous relation between a channel or a bus and a unit. | |
| tresult PLUGIN_API | setUnitProgramData (int32, int32, IBStream *) SMTG_OVERRIDE |
| Receives a preset data stream. | |
| virtual tresult | notifyUnitSelection () |
| Notifies the host about the selected Unit. | |
| void PLUGIN_API | update (FUnknown *changedUnknown, int32 message) SMTG_OVERRIDE |
| Inform the dependent, that the passed FUnknown has changed. | |
Public Member Functions inherited from Steinberg::Vst::EditController | |
| tresult PLUGIN_API | setComponentState (IBStream *state) SMTG_OVERRIDE |
| Receives the component state. | |
| tresult PLUGIN_API | setState (IBStream *state) SMTG_OVERRIDE |
| Sets the controller state. | |
| tresult PLUGIN_API | getState (IBStream *state) SMTG_OVERRIDE |
| Gets the controller state. | |
| int32 PLUGIN_API | getParameterCount () SMTG_OVERRIDE |
| Returns the number of parameters exported. | |
| tresult PLUGIN_API | getParameterInfo (int32 paramIndex, ParameterInfo &info) SMTG_OVERRIDE |
| Gets for a given index the parameter information. | |
| tresult PLUGIN_API | getParamStringByValue (ParamID tag, ParamValue valueNormalized, String128 string) SMTG_OVERRIDE |
| Gets for a given paramID and normalized value its associated string representation. | |
| tresult PLUGIN_API | getParamValueByString (ParamID tag, TChar *string, ParamValue &valueNormalized) SMTG_OVERRIDE |
| Gets for a given paramID and string its normalized value. | |
| ParamValue PLUGIN_API | normalizedParamToPlain (ParamID tag, ParamValue valueNormalized) SMTG_OVERRIDE |
| Returns for a given paramID and a normalized value its plain representation (for example -6 for -6dB - see vst3AutomationIntro). | |
| ParamValue PLUGIN_API | plainParamToNormalized (ParamID tag, ParamValue plainValue) SMTG_OVERRIDE |
| Returns for a given paramID and a plain value its normalized value. | |
| ParamValue PLUGIN_API | getParamNormalized (ParamID tag) SMTG_OVERRIDE |
| Returns the normalized value of the parameter associated to the paramID. | |
| tresult PLUGIN_API | setParamNormalized (ParamID tag, ParamValue value) SMTG_OVERRIDE |
| Sets the normalized value to the parameter associated to the paramID. | |
| tresult PLUGIN_API | setComponentHandler (IComponentHandler *handler) SMTG_OVERRIDE |
| Gets from host a handler which allows the Plugin-in to communicate with the host. | |
| IPlugView *PLUGIN_API | createView (FIDString) SMTG_OVERRIDE |
| Creates the editor view of the plug-in, currently only "editor" is supported, see ViewType. | |
| tresult PLUGIN_API | setKnobMode (KnobMode mode) SMTG_OVERRIDE |
| Host could set the Knob Mode for the plug-in. | |
| tresult PLUGIN_API | openHelp (TBool) SMTG_OVERRIDE |
| Host could ask to open the plug-in help (could be: opening a PDF document or link to a web page). | |
| tresult PLUGIN_API | openAboutBox (TBool) SMTG_OVERRIDE |
| Host could ask to open the plug-in about box. | |
| tresult PLUGIN_API | initialize (FUnknown *context) SMTG_OVERRIDE |
| The host passes a number of interfaces as context to initialize the plug-in class. | |
| virtual tresult | beginEdit (ParamID tag) |
| to be called before a serie of performEdit | |
| virtual tresult | performEdit (ParamID tag, ParamValue valueNormalized) |
| will inform the host about the value change | |
| virtual tresult | endEdit (ParamID tag) |
| to be called after a serie of performEdit | |
| virtual tresult | startGroupEdit () |
| calls IComponentHandler2::startGroupEdit() if host supports it | |
| virtual tresult | finishGroupEdit () |
| calls IComponentHandler2::finishGroupEdit() if host supports it | |
| virtual void | editorDestroyed (EditorView *) |
| called from EditorView if it was destroyed | |
| virtual void | editorAttached (EditorView *) |
| called from EditorView if it was attached to a parent | |
| virtual void | editorRemoved (EditorView *) |
| called from EditorView if it was removed from a parent | |
| virtual Parameter * | getParameterObject (ParamID tag) |
| Gets for a given tag the parameter object. | |
| virtual tresult | getParameterInfoByTag (ParamID tag, ParameterInfo &info) |
| Gets for a given tag the parameter information. | |
| virtual tresult | setDirty (TBool state) |
| Calls IComponentHandler2::setDirty (state) if host supports it. | |
| virtual tresult | requestOpenEditor (FIDString name=ViewType::kEditor) |
| Calls IComponentHandler2::requestOpenEditor (name) if host supports it. | |
| IComponentHandler * | getComponentHandler () const |
Public Member Functions inherited from Steinberg::Vst::ComponentBase | |
| FUnknown * | getHostContext () const |
| Returns the hostContext (set by the host during initialize call). | |
| IConnectionPoint * | getPeer () const |
| Returns the peer for the messaging communication (you can only use IConnectionPoint::notify for communicate between peers, do not try to cast peerConnection. | |
| IMessage * | allocateMessage () const |
| Allocates a message instance (do not forget to release it). | |
| tresult | sendMessage (IMessage *message) const |
| Sends the given message to the peer. | |
| tresult | sendTextMessage (const char8 *text) const |
| Sends a simple text message to the peer (max 255 characters). | |
| tresult | sendMessageID (const char8 *messageID) const |
| Sends a message with a given ID without any other payload. | |
| virtual tresult | receiveText (const char8 *text) |
| Receives a simple text message from the peer (max 255 characters). | |
| tresult PLUGIN_API | connect (IConnectionPoint *other) SMTG_OVERRIDE |
| Connects this instance with another connection point. | |
| tresult PLUGIN_API | disconnect (IConnectionPoint *other) SMTG_OVERRIDE |
| Disconnects a given connection point from this. | |
| tresult PLUGIN_API | notify (IMessage *message) SMTG_OVERRIDE |
| Called when a message has been sent from the connection point to this. | |
Public Member Functions inherited from Steinberg::FObject | |
| FObject ()=default | |
| default constructor... | |
| FObject (const FObject &) | |
| FObject & | operator= (const FObject &) |
| overloads operator "=" as the reference assignment | |
| virtual | ~FObject () |
| destructor... | |
| virtual FClassID | isA () const |
| a local alternative to getFClassID () | |
| virtual bool | isA (FClassID s) const |
| evaluates if the passed ID is of the FObject type | |
| virtual bool | isTypeOf (FClassID s, bool=true) const |
| evaluates if the passed ID is of the FObject type | |
| int32 | getRefCount () |
| returns the current interface reference count | |
| FUnknown * | unknownCast () |
| get FUnknown interface from object | |
| tresult PLUGIN_API | queryInterface (const TUID _iid, void **obj) SMTG_OVERRIDE |
| please refer to FUnknown::queryInterface () | |
| uint32 PLUGIN_API | addRef () SMTG_OVERRIDE |
| please refer to FUnknown::addref () | |
| uint32 PLUGIN_API | release () SMTG_OVERRIDE |
| please refer to FUnknown::release () | |
| void PLUGIN_API | update (FUnknown *, int32) SMTG_OVERRIDE |
| empty virtual method that should be overridden by derived classes for data updates upon changes | |
| virtual void | addDependent (IDependent *dep) |
| adds dependency to the object | |
| virtual void | removeDependent (IDependent *dep) |
| removes dependency from the object | |
| virtual void | changed (int32 msg=kChanged) |
| Inform all dependents, that the object has changed. | |
| virtual void | deferUpdate (int32 msg=kChanged) |
| Similar to triggerUpdates, except only delivered in idle (usefull in collecting updates). | |
| virtual void | updateDone (int32) |
| empty virtual method that should be overridden by derived classes | |
| virtual bool | isEqualInstance (FUnknown *d) |
Protected Types | |
| using | ProgramListVector = std::vector< IPtr< ProgramList > > |
| using | ProgramIndexMap = std::map< ProgramListID, ProgramListVector::size_type > |
| using | UnitVector = std::vector< IPtr< Unit > > |
Protected Attributes | |
| UnitVector | units |
| ProgramListVector | programLists |
| ProgramIndexMap | programIndexMap |
| UnitID | selectedUnit |
Protected Attributes inherited from Steinberg::Vst::EditController | |
| IPtr< IComponentHandler > | componentHandler |
| IPtr< IComponentHandler2 > | componentHandler2 |
| ParameterContainer | parameters |
Protected Attributes inherited from Steinberg::Vst::ComponentBase | |
| IPtr< FUnknown > | hostContext |
| IPtr< IConnectionPoint > | peerConnection |
Protected Attributes inherited from Steinberg::FObject | |
| int32 | refCount |
| COM-model local reference count. | |
Additional Inherited Members | |
Public Types inherited from Steinberg::IDependent | |
| enum | ChangeMessage { kWillChange , kChanged , kDestroyed , kWillDestroy , kStdChangeMessageLast } |
Static Public Member Functions inherited from Steinberg::Vst::EditController | |
| static KnobMode | getHostKnobMode () |
| return host knob mode | |
Static Public Member Functions inherited from Steinberg::FObject | |
| static FClassID | getFClassID () |
| return Class ID as an ASCII string (statically) | |
| static void | setUpdateHandler (IUpdateHandler *handler) |
| set method for the local attribute | |
| static IUpdateHandler * | getUpdateHandler () |
| get method for the local attribute | |
| static bool | classIDsEqual (FClassID ci1, FClassID ci2) |
| compares (evaluates) 2 class IDs | |
| static FObject * | unknownToObject (FUnknown *unknown) |
| pointer conversion from FUnknown to FObject | |
Static Public Attributes inherited from Steinberg::FObject | |
| static const FUID | iid |
| Special UID that is used to cast an FUnknown pointer to a FObject. | |
Static Public Attributes inherited from Steinberg::IDependent | |
| static const FUID | iid |
Static Public Attributes inherited from Steinberg::FUnknown | |
| static const FUID | iid |
Static Public Attributes inherited from Steinberg::IPluginBase | |
| static const FUID | iid |
Static Public Attributes inherited from Steinberg::Vst::IConnectionPoint | |
| static const FUID | iid |
Static Public Attributes inherited from Steinberg::Vst::IEditController | |
| static const FUID | iid |
Static Public Attributes inherited from Steinberg::Vst::IEditController2 | |
| static const FUID | iid |
Static Public Attributes inherited from Steinberg::Vst::IUnitInfo | |
| static const FUID | iid |
Static Protected Attributes inherited from Steinberg::Vst::EditController | |
| static KnobMode | hostKnobMode |
Static Protected Attributes inherited from Steinberg::FObject | |
| static IUpdateHandler * | gUpdateHandler |
Advanced implementation (support IUnitInfo) for a VST 3 edit controller.
Definition at line 288 of file vsteditcontroller.h.
|
protected |
Definition at line 364 of file vsteditcontroller.h.
|
protected |
Definition at line 363 of file vsteditcontroller.h.
|
protected |
Definition at line 365 of file vsteditcontroller.h.
| Steinberg::Vst::EditControllerEx1::EditControllerEx1 | ( | ) |
Definition at line 316 of file vsteditcontroller.cpp.
|
override |
Definition at line 322 of file vsteditcontroller.cpp.
| bool Steinberg::Vst::EditControllerEx1::addProgramList | ( | ProgramList * | list | ) |
Adds a given program list.
Definition at line 373 of file vsteditcontroller.cpp.
Adds a given unit.
Definition at line 343 of file vsteditcontroller.cpp.
|
virtual |
Gets for a given program list ID, program index and attributeId the associated attribute value.
Implements Steinberg::Vst::IUnitInfo.
Definition at line 439 of file vsteditcontroller.cpp.
| ProgramList * Steinberg::Vst::EditControllerEx1::getProgramList | ( | ProgramListID | listId | ) | const |
Returns the ProgramList associated to a given listId.
Definition at line 382 of file vsteditcontroller.cpp.
|
virtual |
Component intern program structure.
Gets the count of Program List.
Implements Steinberg::Vst::IUnitInfo.
Definition at line 399 of file vsteditcontroller.cpp.
|
virtual |
Gets for a given index the Program List Info.
Implements Steinberg::Vst::IUnitInfo.
Definition at line 405 of file vsteditcontroller.cpp.
|
virtual |
Gets for a given program list ID and program index its program name.
Implements Steinberg::Vst::IUnitInfo.
Definition at line 415 of file vsteditcontroller.cpp.
|
virtual |
Gets the PitchName for a given program list ID, program index and pitch.
If PitchNames are changed the plug-in should inform the host with IUnitHandler::notifyProgramListChange.
Implements Steinberg::Vst::IUnitInfo.
Definition at line 464 of file vsteditcontroller.cpp.
|
virtual |
Gets the current selected unit.
Implements Steinberg::Vst::IUnitInfo.
Definition at line 331 of file vsteditcontroller.h.
|
virtual |
Gets the according unit if there is an unambiguous relation between a channel or a bus and a unit.
This method mainly is intended to find out which unit is related to a given MIDI input channel.
Implements Steinberg::Vst::IUnitInfo.
Definition at line 338 of file vsteditcontroller.h.
|
virtual |
Returns the flat count of units.
Implements Steinberg::Vst::IUnitInfo.
Definition at line 310 of file vsteditcontroller.h.
|
virtual |
Gets UnitInfo for a given index in the flat list of unit.
Implements Steinberg::Vst::IUnitInfo.
Definition at line 350 of file vsteditcontroller.cpp.
|
virtual |
Returns kResultTrue if the given program index of a given program list ID supports PitchNames.
Implements Steinberg::Vst::IUnitInfo.
Definition at line 452 of file vsteditcontroller.cpp.
| tresult Steinberg::Vst::EditControllerEx1::notifyProgramListChange | ( | ProgramListID | listId, |
| int32 | programIndex = kAllProgramInvalid |
||
| ) |
Notifies the host about program list changes.
Definition at line 389 of file vsteditcontroller.cpp.
|
virtual |
Notifies the host about the selected Unit.
Definition at line 363 of file vsteditcontroller.cpp.
|
virtual |
Sets a new selected unit.
Implements Steinberg::Vst::IUnitInfo.
Definition at line 332 of file vsteditcontroller.h.
|
virtual |
Definition at line 427 of file vsteditcontroller.cpp.
|
virtual |
Receives a preset data stream.
Implements Steinberg::Vst::IUnitInfo.
Definition at line 343 of file vsteditcontroller.h.
|
virtual |
This function is called before the plug-in is unloaded and can be used for cleanups.
You have to release all references to any host application interfaces.
Reimplemented from Steinberg::Vst::EditController.
Definition at line 327 of file vsteditcontroller.cpp.
|
virtual |
Inform the dependent, that the passed FUnknown has changed.
Implements Steinberg::IDependent.
Definition at line 476 of file vsteditcontroller.cpp.
|
protected |
Definition at line 368 of file vsteditcontroller.h.
|
protected |
Definition at line 367 of file vsteditcontroller.h.
|
protected |
Definition at line 369 of file vsteditcontroller.h.
|
protected |
Definition at line 366 of file vsteditcontroller.h.