VST 3 SDK VST 3.7
SDK for developing VST plug-in
SingleComponentEffect Class Reference

Default implementation for a non-distributable Plug-in that combines processor and edit controller in one component. More...

#include <vstsinglecomponenteffect.h>

+ Inheritance diagram for SingleComponentEffect:

Public Member Functions

 SingleComponentEffect ()
 
virtual ~SingleComponentEffect ()
 
tresult initialize (FUnknown *context) SMTG_OVERRIDE
 
tresult terminate () SMTG_OVERRIDE
 
tresult getControllerClassId (TUID) SMTG_OVERRIDE
 
tresult setIoMode (IoMode) SMTG_OVERRIDE
 
int32 getBusCount (MediaType type, BusDirection dir) SMTG_OVERRIDE
 
tresult getBusInfo (MediaType type, BusDirection dir, int32 index, BusInfo &bus) SMTG_OVERRIDE
 
tresult getRoutingInfo (RoutingInfo &, RoutingInfo &) SMTG_OVERRIDE
 
tresult activateBus (MediaType type, BusDirection dir, int32 index, TBool state) SMTG_OVERRIDE
 
tresult setActive (TBool) SMTG_OVERRIDE
 
tresult setState (IBStream *) SMTG_OVERRIDE
 
tresult getState (IBStream *) SMTG_OVERRIDE
 
AudioBusaddAudioInput (const TChar *name, SpeakerArrangement arr, BusType busType=kMain, int32 flags=BusInfo::kDefaultActive)
 
AudioBusaddAudioOutput (const TChar *name, SpeakerArrangement arr, BusType busType=kMain, int32 flags=BusInfo::kDefaultActive)
 
EventBusaddEventInput (const TChar *name, int32 channels=16, BusType busType=kMain, int32 flags=BusInfo::kDefaultActive)
 
EventBusaddEventOutput (const TChar *name, int32 channels=16, BusType busType=kMain, int32 flags=BusInfo::kDefaultActive)
 
tresult removeAudioBusses ()
 
tresult removeEventBusses ()
 
tresult removeAllBusses ()
 
tresult setBusArrangements (SpeakerArrangement *inputs, int32 numIns, SpeakerArrangement *outputs, int32 numOuts) SMTG_OVERRIDE
 
tresult getBusArrangement (BusDirection dir, int32 index, SpeakerArrangement &arr) SMTG_OVERRIDE
 
tresult canProcessSampleSize (int32 symbolicSampleSize) SMTG_OVERRIDE
 
uint32 getLatencySamples () SMTG_OVERRIDE
 
tresult setupProcessing (ProcessSetup &setup) SMTG_OVERRIDE
 
tresult setProcessing (TBool) SMTG_OVERRIDE
 
tresult process (ProcessData &) SMTG_OVERRIDE
 
uint32 getTailSamples () SMTG_OVERRIDE
 
uint32 getProcessContextRequirements () SMTG_OVERRIDE
 
 OBJ_METHODS (SingleComponentEffect, EditControllerEx1) tresult queryInterface(const TUID iid
 
- Public Member Functions inherited from EditControllerEx1
 EditControllerEx1 ()
 
 ~EditControllerEx1 () override
 
tresult terminate () SMTG_OVERRIDE
 
bool addUnit (Unit *unit)
 Adds a given unit. More...
 
bool addProgramList (ProgramList *list)
 Adds a given program list. More...
 
ProgramListgetProgramList (ProgramListID listId) const
 Returns the ProgramList associated to a given listId. More...
 
tresult notifyProgramListChange (ProgramListID listId, int32 programIndex=kAllProgramInvalid)
 Notifies the host about program list changes. More...
 
int32 getUnitCount () SMTG_OVERRIDE
 
tresult getUnitInfo (int32 unitIndex, UnitInfo &info) SMTG_OVERRIDE
 
int32 getProgramListCount () SMTG_OVERRIDE
 
tresult getProgramListInfo (int32 listIndex, ProgramListInfo &info) SMTG_OVERRIDE
 
tresult getProgramName (ProgramListID listId, int32 programIndex, String128 name) SMTG_OVERRIDE
 
tresult getProgramInfo (ProgramListID listId, int32 programIndex, CString attributeId, String128 attributeValue) SMTG_OVERRIDE
 
tresult hasProgramPitchNames (ProgramListID listId, int32 programIndex) SMTG_OVERRIDE
 
tresult getProgramPitchName (ProgramListID listId, int32 programIndex, int16 midiPitch, String128 name) SMTG_OVERRIDE
 
virtual tresult setProgramName (ProgramListID listId, int32 programIndex, const String128 name)
 
UnitID getSelectedUnit () SMTG_OVERRIDE
 
tresult selectUnit (UnitID unitId) SMTG_OVERRIDE
 
tresult getUnitByBus (MediaType, BusDirection, int32, int32, UnitID &) SMTG_OVERRIDE
 
tresult setUnitProgramData (int32, int32, IBStream *) SMTG_OVERRIDE
 
virtual tresult notifyUnitSelection ()
 Notifies the host about the selected Unit. More...
 
void update (FUnknown *changedUnknown, int32 message) SMTG_OVERRIDE
 
- Public Member Functions inherited from EditController
 EditController ()
 
tresult setComponentState (IBStream *state) SMTG_OVERRIDE
 
tresult setState (IBStream *state) SMTG_OVERRIDE
 
tresult getState (IBStream *state) SMTG_OVERRIDE
 
int32 getParameterCount () SMTG_OVERRIDE
 
tresult getParameterInfo (int32 paramIndex, ParameterInfo &info) SMTG_OVERRIDE
 
tresult getParamStringByValue (ParamID tag, ParamValue valueNormalized, String128 string) SMTG_OVERRIDE
 
tresult getParamValueByString (ParamID tag, TChar *string, ParamValue &valueNormalized) SMTG_OVERRIDE
 
ParamValue normalizedParamToPlain (ParamID tag, ParamValue valueNormalized) SMTG_OVERRIDE
 
ParamValue plainParamToNormalized (ParamID tag, ParamValue plainValue) SMTG_OVERRIDE
 
ParamValue getParamNormalized (ParamID tag) SMTG_OVERRIDE
 
tresult setParamNormalized (ParamID tag, ParamValue value) SMTG_OVERRIDE
 
tresult setComponentHandler (IComponentHandler *handler) SMTG_OVERRIDE
 
IPlugViewcreateView (FIDString) SMTG_OVERRIDE
 
tresult setKnobMode (KnobMode mode) SMTG_OVERRIDE
 
tresult openHelp (TBool) SMTG_OVERRIDE
 
tresult openAboutBox (TBool) SMTG_OVERRIDE
 
tresult initialize (FUnknown *context) SMTG_OVERRIDE
 
tresult terminate () SMTG_OVERRIDE
 
virtual tresult beginEdit (ParamID tag)
 to be called before a serie of performEdit More...
 
virtual tresult performEdit (ParamID tag, ParamValue valueNormalized)
 will inform the host about the value change More...
 
virtual tresult endEdit (ParamID tag)
 to be called after a serie of performEdit More...
 
virtual tresult startGroupEdit ()
 calls IComponentHandler2::startGroupEdit() if host supports it More...
 
virtual tresult finishGroupEdit ()
 calls IComponentHandler2::finishGroupEdit() if host supports it More...
 
virtual void editorDestroyed (EditorView *)
 called from EditorView if it was destroyed More...
 
virtual void editorAttached (EditorView *)
 called from EditorView if it was attached to a parent More...
 
virtual void editorRemoved (EditorView *)
 called from EditorView if it was removed from a parent More...
 
virtual ParametergetParameterObject (ParamID tag)
 Gets for a given tag the parameter object. More...
 
virtual tresult getParameterInfoByTag (ParamID tag, ParameterInfo &info)
 Gets for a given tag the parameter information. More...
 
virtual tresult setDirty (TBool state)
 Calls IComponentHandler2::setDirty (state) if host supports it. More...
 
virtual tresult requestOpenEditor (FIDString name=ViewType::kEditor)
 Calls IComponentHandler2::requestOpenEditor (name) if host supports it. More...
 
IComponentHandlergetComponentHandler () const
 
- Public Member Functions inherited from ComponentBase
 ComponentBase ()
 
 ~ComponentBase () override
 
FUnknowngetHostContext () const
 Returns the hostContext (set by the host during initialize call). More...
 
IConnectionPointgetPeer () const
 Returns the peer for the messaging communication (you can only use IConnectionPoint::notify for communicate between peers, do not try to cast peerConnection. More...
 
IMessageallocateMessage () const
 Allocates a message instance (do not forget to release it). More...
 
tresult sendMessage (IMessage *message) const
 Sends the given message to the peer. More...
 
tresult sendTextMessage (const char8 *text) const
 Sends a simple text message to the peer (max 255 characters). More...
 
tresult sendMessageID (const char8 *messageID) const
 Sends a message with a given ID without any other payload. More...
 
virtual tresult receiveText (const char8 *text)
 Receives a simple text message from the peer (max 255 characters). More...
 
tresult initialize (FUnknown *context) SMTG_OVERRIDE
 
tresult terminate () SMTG_OVERRIDE
 
tresult connect (IConnectionPoint *other) SMTG_OVERRIDE
 
tresult disconnect (IConnectionPoint *other) SMTG_OVERRIDE
 
tresult notify (IMessage *message) SMTG_OVERRIDE
 
virtual tresult initialize (FUnknown *context)=0
 
virtual tresult terminate ()=0
 
- Public Member Functions inherited from FUnknown
virtual tresult queryInterface (const TUID _iid, void **obj)=0
 
virtual uint32 addRef ()=0
 
virtual uint32 release ()=0
 
virtual tresult connect (IConnectionPoint *other)=0
 
virtual tresult disconnect (IConnectionPoint *other)=0
 
virtual tresult notify (IMessage *message)=0
 
virtual tresult setComponentState (IBStream *state)=0
 
virtual tresult setState (IBStream *state)=0
 
virtual tresult getState (IBStream *state)=0
 
virtual int32 getParameterCount ()=0
 
virtual tresult getParameterInfo (int32 paramIndex, ParameterInfo &info)=0
 
virtual tresult getParamStringByValue (ParamID id, ParamValue valueNormalized, String128 string)=0
 
virtual tresult getParamValueByString (ParamID id, TChar *string, ParamValue &valueNormalized)=0
 
virtual ParamValue normalizedParamToPlain (ParamID id, ParamValue valueNormalized)=0
 
virtual ParamValue plainParamToNormalized (ParamID id, ParamValue plainValue)=0
 
virtual ParamValue getParamNormalized (ParamID id)=0
 
virtual tresult setParamNormalized (ParamID id, ParamValue value)=0
 
virtual tresult setComponentHandler (IComponentHandler *handler)=0
 
virtual IPlugViewcreateView (FIDString name)=0
 
virtual tresult setKnobMode (KnobMode mode)=0
 
virtual tresult openHelp (TBool onlyCheck)=0
 
virtual tresult openAboutBox (TBool onlyCheck)=0
 
virtual int32 getUnitCount ()=0
 
virtual tresult getUnitInfo (int32 unitIndex, UnitInfo &info)=0
 
virtual int32 getProgramListCount ()=0
 
virtual tresult getProgramListInfo (int32 listIndex, ProgramListInfo &info)=0
 
virtual tresult getProgramName (ProgramListID listId, int32 programIndex, String128 name)=0
 
virtual tresult getProgramInfo (ProgramListID listId, int32 programIndex, CString attributeId, String128 attributeValue)=0
 
virtual tresult hasProgramPitchNames (ProgramListID listId, int32 programIndex)=0
 
virtual tresult getProgramPitchName (ProgramListID listId, int32 programIndex, int16 midiPitch, String128 name)=0
 
virtual UnitID getSelectedUnit ()=0
 
virtual tresult selectUnit (UnitID unitId)=0
 
virtual tresult getUnitByBus (MediaType type, BusDirection dir, int32 busIndex, int32 channel, UnitID &unitId)=0
 
virtual tresult setUnitProgramData (int32 listOrUnitId, int32 programIndex, IBStream *data)=0
 
virtual tresult getControllerClassId (TUID classId)=0
 
virtual tresult setIoMode (IoMode mode)=0
 
virtual int32 getBusCount (MediaType type, BusDirection dir)=0
 
virtual tresult getBusInfo (MediaType type, BusDirection dir, int32 index, BusInfo &bus)=0
 
virtual tresult getRoutingInfo (RoutingInfo &inInfo, RoutingInfo &outInfo)=0
 
virtual tresult activateBus (MediaType type, BusDirection dir, int32 index, TBool state)=0
 
virtual tresult setActive (TBool state)=0
 
virtual tresult setState (IBStream *state)=0
 
virtual tresult getState (IBStream *state)=0
 
virtual tresult setBusArrangements (SpeakerArrangement *inputs, int32 numIns, SpeakerArrangement *outputs, int32 numOuts)=0
 
virtual tresult getBusArrangement (BusDirection dir, int32 index, SpeakerArrangement &arr)=0
 
virtual tresult canProcessSampleSize (int32 symbolicSampleSize)=0
 
virtual uint32 getLatencySamples ()=0
 
virtual tresult setupProcessing (ProcessSetup &setup)=0
 
virtual tresult setProcessing (TBool state)=0
 
virtual tresult process (ProcessData &data)=0
 
virtual uint32 getTailSamples ()=0
 
virtual uint32 getProcessContextRequirements ()=0
 

Public Attributes

void **obj SMTG_OVERRIDE
 
REFCOUNT_METHODS(EditControllerEx1) protected ProcessSetup processSetup
 
ProcessContextRequirements processContextRequirements
 
BusList audioInputs
 
BusList audioOutputs
 
BusList eventInputs
 
BusList eventOutputs
 
- Public Attributes inherited from EditControllerEx1
UnitVector units
 
ProgramListVector programLists
 
ProgramIndexMap programIndexMap
 
UnitID selectedUnit {kRootUnitId}
 
- Public Attributes inherited from EditController
OBJ_METHODS(EditController, ComponentBase) DEFINE_INTERFACES DEF_INTERFACE(IEditController) DEF_INTERFACE(IEditController2) END_DEFINE_INTERFACES(ComponentBase) REFCOUNT_METHODS(ComponentBase) protected IPtr< IComponentHandler2componentHandler2
 
ParameterContainer parameters
 
- Public Attributes inherited from ComponentBase
OBJ_METHODS(ComponentBase, FObject) DEFINE_INTERFACES DEF_INTERFACE(IPluginBase) DEF_INTERFACE(IConnectionPoint) END_DEFINE_INTERFACES(FObject) REFCOUNT_METHODS(FObject) protected IPtr< IConnectionPointpeerConnection
 
- Public Attributes inherited from IProcessContextRequirements
 kNeedSystemTime
 
 kNeedContinousTimeSamples
 
 kNeedProjectTimeMusic
 
 kNeedBarPositionMusic
 
 kNeedCycleMusic
 
 kNeedSamplesToNextClock
 
 kNeedTempo
 
 kNeedTimeSignature
 
 kNeedChord
 
 kNeedFrameRate
 
 kNeedTransportState
 

Additional Inherited Members

- Public Types inherited from EditControllerEx1
using ProgramIndexMap = (EditControllerEx1, EditController) DEFINE_INTERFACES DEF_INTERFACE(IUnitInfo) END_DEFINE_INTERFACES(EditController) REFCOUNT_METHODS(EditController) protected std::map< ProgramListID, ProgramListVector::size_type >
 
using UnitVector = std::vector< IPtr< Unit > >
 
- Public Types inherited from IProcessContextRequirements
enum  Flags
 
- Static Public Member Functions inherited from EditController
static KnobMode getHostKnobMode ()
 return host knob mode More...
 
- Static Public Attributes inherited from EditController
static KnobMode hostKnobMode = kCircularMode
 
- Static Public Attributes inherited from IPluginBase
static const FUID iid
 
- Static Public Attributes inherited from FUnknown
static const FUID iid
 
- Static Public Attributes inherited from IConnectionPoint
static const FUID iid
 
- Static Public Attributes inherited from IEditController
static const FUID iid
 
- Static Public Attributes inherited from IEditController2
static const FUID iid
 
- Static Public Attributes inherited from IUnitInfo
static const FUID iid
 
- Static Public Attributes inherited from IComponent
static const FUID iid
 
- Static Public Attributes inherited from IAudioProcessor
static const FUID iid
 
- Static Public Attributes inherited from IProcessContextRequirements
static const FUID iid
 

Detailed Description

Default implementation for a non-distributable Plug-in that combines processor and edit controller in one component.

  • [released: 3.0.2]

This can be used as base class for a VST 3 effect implementation in case that the standard way of defining two separate components would cause too many implementation difficulties:

  • Cubase 4.2 is the first host that supports combined VST 3 Plug-ins
  • Use this class only after giving the standard way of defining two components serious considerations!

Constructor & Destructor Documentation

◆ SingleComponentEffect()

◆ ~SingleComponentEffect()

~SingleComponentEffect ( )
virtual

Member Function Documentation

◆ initialize()

tresult initialize ( FUnknown context)
virtual

Implements IPluginBase.

◆ terminate()

tresult terminate ( )
virtual

Reimplemented from EditControllerEx1.

◆ getControllerClassId()

tresult getControllerClassId ( TUID  )
inlinevirtual

Implements IComponent.

◆ setIoMode()

tresult setIoMode ( IoMode  )
inlinevirtual

Implements IComponent.

◆ getBusCount()

int32 getBusCount ( MediaType  type,
BusDirection  dir 
)
virtual

Implements IComponent.

◆ getBusInfo()

tresult getBusInfo ( MediaType  type,
BusDirection  dir,
int32  index,
BusInfo bus 
)
virtual

Implements IComponent.

◆ getRoutingInfo()

tresult getRoutingInfo ( RoutingInfo ,
RoutingInfo  
)
inlinevirtual

Implements IComponent.

◆ activateBus()

tresult activateBus ( MediaType  type,
BusDirection  dir,
int32  index,
TBool  state 
)
virtual

Implements IComponent.

◆ setActive()

tresult setActive ( TBool  )
inlinevirtual

Implements IComponent.

◆ setState()

tresult setState ( IBStream )
inlinevirtual

Implements IComponent.

◆ getState()

tresult getState ( IBStream )
inlinevirtual

Implements IComponent.

◆ addAudioInput()

AudioBus * addAudioInput ( const TChar name,
SpeakerArrangement  arr,
BusType  busType = kMain,
int32  flags = BusInfo::kDefaultActive 
)

◆ addAudioOutput()

AudioBus * addAudioOutput ( const TChar name,
SpeakerArrangement  arr,
BusType  busType = kMain,
int32  flags = BusInfo::kDefaultActive 
)

◆ addEventInput()

EventBus * addEventInput ( const TChar name,
int32  channels = 16,
BusType  busType = kMain,
int32  flags = BusInfo::kDefaultActive 
)

◆ addEventOutput()

EventBus * addEventOutput ( const TChar name,
int32  channels = 16,
BusType  busType = kMain,
int32  flags = BusInfo::kDefaultActive 
)

◆ removeAudioBusses()

tresult removeAudioBusses ( )

◆ removeEventBusses()

tresult removeEventBusses ( )

◆ removeAllBusses()

tresult removeAllBusses ( )

◆ setBusArrangements()

tresult setBusArrangements ( SpeakerArrangement inputs,
int32  numIns,
SpeakerArrangement outputs,
int32  numOuts 
)
virtual

Implements IAudioProcessor.

◆ getBusArrangement()

tresult getBusArrangement ( BusDirection  dir,
int32  index,
SpeakerArrangement arr 
)
virtual

Implements IAudioProcessor.

◆ canProcessSampleSize()

tresult canProcessSampleSize ( int32  symbolicSampleSize)
virtual

Implements IAudioProcessor.

◆ getLatencySamples()

uint32 getLatencySamples ( )
inlinevirtual

Implements IAudioProcessor.

◆ setupProcessing()

tresult setupProcessing ( ProcessSetup setup)
virtual

Implements IAudioProcessor.

◆ setProcessing()

tresult setProcessing ( TBool  )
inlinevirtual

Implements IAudioProcessor.

◆ process()

tresult process ( ProcessData )
inlinevirtual

Implements IAudioProcessor.

◆ getTailSamples()

uint32 getTailSamples ( )
inlinevirtual

Implements IAudioProcessor.

◆ getProcessContextRequirements()

uint32 getProcessContextRequirements ( )
inlinevirtual

◆ OBJ_METHODS()

OBJ_METHODS ( SingleComponentEffect  ,
EditControllerEx1   
) const

Member Data Documentation

◆ SMTG_OVERRIDE

void** obj SMTG_OVERRIDE

◆ processSetup

REFCOUNT_METHODS (EditControllerEx1) protected ProcessSetup processSetup

◆ processContextRequirements

ProcessContextRequirements processContextRequirements

◆ audioInputs

BusList audioInputs

◆ audioOutputs

BusList audioOutputs

◆ eventInputs

BusList eventInputs

◆ eventOutputs

BusList eventOutputs
Empty

Copyright © Steinberg Media Technologies GmbH. All Rights Reserved. This documentation is under this license.