Jamba  3.0.2
pongasoft::VST::GUI::Params::GUIVstParameter< T > Class Template Reference

#include <GUIVstParameter.h>

Classes

class  Editor
 

Public Types

using ParamType = T
 

Public Member Functions

std::unique_ptr< FObjectCxconnect (Parameters::IChangeListener *iChangeListener) const
 
std::unique_ptr< FObjectCxconnect (Parameters::ChangeCallback iChangeCallback) const
 
std::unique_ptr< Editoredit ()
 
std::unique_ptr< Editoredit (ParamType iValue)
 
ParamValue getNormalizedValue () const
 
ParamID getParamID () const
 
ParamType getValue () const
 
 GUIVstParameter (std::shared_ptr< GUIRawVstParameter > iRawParameter, std::shared_ptr< VstParamDef< T >> iVstParamDef)
 
tresult setNormalizedValue (ParamValue const &iNormalizedValue)
 
tresult setValue (ParamType const &iValue)
 
void toString (String128 oString)
 
String toString ()
 
 ~GUIVstParameter ()
 

Private Attributes

std::shared_ptr< GUIRawVstParameterfRawParameter
 
std::shared_ptr< VstParamDef< T > > fVstParamDef
 

Detailed Description

template<typename T>
class pongasoft::VST::GUI::Params::GUIVstParameter< T >

This class wraps a GUIRawVstParameter to deal with any type T

Member Typedef Documentation

◆ ParamType

template<typename T >
using pongasoft::VST::GUI::Params::GUIVstParameter< T >::ParamType = T

Constructor & Destructor Documentation

◆ GUIVstParameter()

template<typename T >
pongasoft::VST::GUI::Params::GUIVstParameter< T >::GUIVstParameter ( std::shared_ptr< GUIRawVstParameter iRawParameter,
std::shared_ptr< VstParamDef< T >>  iVstParamDef 
)
inline

◆ ~GUIVstParameter()

template<typename T >
pongasoft::VST::GUI::Params::GUIVstParameter< T >::~GUIVstParameter ( )
inline

Member Function Documentation

◆ connect() [1/2]

template<typename T >
std::unique_ptr<FObjectCx> pongasoft::VST::GUI::Params::GUIVstParameter< T >::connect ( Parameters::IChangeListener iChangeListener) const
inline
Returns
an object maintaining the connection between the parameter and the listener

◆ connect() [2/2]

template<typename T >
std::unique_ptr<FObjectCx> pongasoft::VST::GUI::Params::GUIVstParameter< T >::connect ( Parameters::ChangeCallback  iChangeCallback) const
inline
Returns
an object maintaining the connection between the parameter and the callback

◆ edit() [1/2]

template<typename T >
std::unique_ptr<Editor> pongasoft::VST::GUI::Params::GUIVstParameter< T >::edit ( )
inline
Returns
an editor to modify the parameter (see Editor)

◆ edit() [2/2]

template<typename T >
std::unique_ptr<Editor> pongasoft::VST::GUI::Params::GUIVstParameter< T >::edit ( ParamType  iValue)
inline

Shortcut to create an editor and set the value to it

Returns
an editor to modify the parameter (see Editor)

◆ getNormalizedValue()

template<typename T >
ParamValue pongasoft::VST::GUI::Params::GUIVstParameter< T >::getNormalizedValue ( ) const
inline
Returns
the current value of the parameter as a normalized value

◆ getParamID()

template<typename T >
ParamID pongasoft::VST::GUI::Params::GUIVstParameter< T >::getParamID ( ) const
inline

◆ getValue()

template<typename T >
ParamType pongasoft::VST::GUI::Params::GUIVstParameter< T >::getValue ( ) const
inline
Returns
the current value of the parameter as a T (using the Denormalizer)

◆ setNormalizedValue()

template<typename T >
tresult pongasoft::VST::GUI::Params::GUIVstParameter< T >::setNormalizedValue ( ParamValue const &  iNormalizedValue)
inline

Sets the value of this parameter as a normalized value. Note that this is "transactional" and if you want to make further changes that spans multiple calls (ex: onMouseDown / onMouseMoved / onMouseUp) you should use an editor

◆ setValue()

template<typename T >
tresult pongasoft::VST::GUI::Params::GUIVstParameter< T >::setValue ( ParamType const &  iValue)
inline

Sets the value of this parameter. Note that this is "transactional" and if you want to make further changes that spans multiple calls (ex: onMouseDown / onMouseMoved / onMouseUp) you should use an editor

◆ toString() [1/2]

template<typename T >
void pongasoft::VST::GUI::Params::GUIVstParameter< T >::toString ( String128  oString)
inline

Populates the oString with a string representation of this parameter

◆ toString() [2/2]

template<typename T >
String pongasoft::VST::GUI::Params::GUIVstParameter< T >::toString ( )
inline

Returns a string representation of this parameter

Member Data Documentation

◆ fRawParameter

template<typename T >
std::shared_ptr<GUIRawVstParameter> pongasoft::VST::GUI::Params::GUIVstParameter< T >::fRawParameter
private

◆ fVstParamDef

template<typename T >
std::shared_ptr<VstParamDef<T> > pongasoft::VST::GUI::Params::GUIVstParameter< T >::fVstParamDef
private

The documentation for this class was generated from the following file: