76 template<
typename T,
size_t N>
88 template<
typename T,
size_t N>
100 template<
typename T,
size_t N>
105 virtual tresult
init();
187 tresult
addRawParameter(std::unique_ptr<RTRawVstParameter> iParameter);
247 std::unique_ptr<RTRawVstParameter> rtParam{rawPtr};
264template<
typename T,
size_t N>
278 std::unique_ptr<IRTJmbOutParameter> rtParam{rawPtr};
286template<
typename T,
size_t N>
300 std::unique_ptr<IRTJmbInParameter> rtParam{rawPtr};
309template<
typename T,
size_t N>
This is the lock free version of the AtomicValue.
Definition Concurrent.h:319
This is the lock free version of the SingleElementQueue.
Definition Concurrent.h:150
This helper class is used to display the parameters (vst/jmb) WARNING: this class is allocating memor...
Definition ParamDisplay.h:35
Interface defining a message handler.
Definition MessageHandler.h:32
Abstraction for allocating and sending a message.
Definition MessageProducer.h:35
Simple implementation of IMessageHandler which will delegate the message handling based on MessageID.
Definition MessageHandler.h:41
Simple wrapper class with better api.
Definition Messaging.h:46
Used to communicate the state between the UI and the RT and read/write to stream.
Definition NormalizedState.h:39
This is the class which maintains all the registered parameters.
Definition Parameters.h:39
This is the main class that the plugin should use as it exposes only the necessary methods of the par...
Definition RTJmbInParameter.h:142
Templated class for RT Jamba Inbound parameter.
Definition RTJmbInParameter.h:72
This is the main class that the plugin should use as it exposes only the necessary methods of the par...
Definition RTJmbOutParameter.h:172
Templated class for RT Jamba parameter.
Definition RTJmbOutParameter.h:71
This is the main class that the plugin should use as it exposes only the necessary methods of the par...
Definition RTParameter.h:277
bool isMessagingEnabled() const
Definition RTState.h:149
RTState(Parameters const &iParameters)
Definition RTState.cpp:26
std::map< ParamID, std::unique_ptr< IRTJmbInParameter > > fInboundMessagingParameters
Definition RTState.h:177
tresult addInboundMessagingParameter(std::unique_ptr< IRTJmbInParameter > iParameter)
Definition RTState.cpp:116
tresult handleMessage(Message const &iMessage) override
Called by the UI thread (from RTProcessor) to handle messages.
Definition RTState.cpp:369
virtual bool beforeProcessing()
This method should be call at the beginning of the process(ProcessData &data) method before doing any...
Definition RTState.cpp:275
tresult addOutboundMessagingParameter(std::unique_ptr< IRTJmbOutParameter > iParameter)
Definition RTState.cpp:81
std::map< ParamID, std::unique_ptr< IRTJmbOutParameter > > fOutboundMessagingParameters
Definition RTState.h:174
std::vector< ParamID > const & getAllRegistrationOrder() const
Definition RTState.h:161
virtual void afterProcessing()
This method should be called at the end of process(ProcessData &data) method.
Definition RTState.cpp:308
virtual tresult sendPendingMessages(IMessageProducer *iMessageProducer)
Called (from a GUI timer) to send the messages to the GUI (JmbParam for the moment).
Definition RTState.cpp:334
virtual tresult writeLatestState(IBStreamer &oStreamer)
This method should be called from Processor::getState to store the latest state to the stream.
Definition RTState.cpp:263
tresult addRawParameter(std::unique_ptr< RTRawVstParameter > iParameter)
Definition RTState.cpp:52
RTJmbInParam< T > addJmbIn(JmbParam< T > iParamDef)
This method should be called to add an rt inbound jmb parameter.
Definition RTState.h:296
virtual int32 getParamUpdateSampleOffset(ProcessData &iData, ParamID iParamID) const
This uses the same algorithm as when the param value is updated (implemented in applyParameterChanges...
Definition RTState.cpp:187
RTRawVstParam add(RawVstParam iParamDef)
This method is called for each parameter managed by RTState.
Definition RTState.cpp:36
Concurrent::LockFree::AtomicValue< NormalizedState > fLatestState
Definition RTState.h:232
Parameters const & fPluginParameters
Definition RTState.h:168
virtual bool resetPreviousValues()
Called from the RT thread from afterProcessing to reset previous values (copy current value to previo...
Definition RTState.cpp:320
std::map< ParamID, std::unique_ptr< RTRawVstParameter > > fVstParameters
Definition RTState.h:171
virtual void afterReadNewState(NormalizedState const *iState)
Gives a chance to subclasses to tweak and/or display the state after being read.
Definition RTState.h:215
std::vector< ParamID > fAllRegistrationOrder
Definition RTState.h:180
MessageHandler fMessageHandler
Definition RTState.h:183
virtual bool onNewState(NormalizedState const *iLatestState)
Called from the RT thread from beforeProcessing to set the new state.
Definition RTState.cpp:291
virtual tresult init()
Call this method after adding all the parameters.
Definition RTState.cpp:377
virtual void beforeWriteNewState(NormalizedState const *iState)
Gives a chance to subclasses to tweak and/or display the state before being written.
Definition RTState.h:219
virtual tresult readNewState(IBStreamer &iStreamer)
This method should be called from Processor::setState to update this state to the state stored in the...
Definition RTState.cpp:247
virtual bool applyParameterChanges(IParameterChanges &inputParameterChanges)
This method should be called in every frame when there are parameter changes to update this state acc...
Definition RTState.cpp:152
void computeLatestState()
Definition RTState.cpp:237
RTJmbOutParam< T > addJmbOut(JmbParam< T > iParamDef)
This method should be called to add an rt outbound jmb parameter.
Definition RTState.h:274
Concurrent::LockFree::SingleElementQueue< NormalizedState > fStateUpdate
Definition RTState.h:228
This is the main class that the plugin should use as it exposes only the necessary methods of the par...
Definition RTParameter.h:192
The typed version.
Definition RTParameter.h:93
Definition ParamDisplay.cpp:29
Definition RTJmbInParameter.h:26
std::array< RTRawVstParam, N > RTRawVstParams
Definition RTParameter.h:343
std::array< RTJmbInParam< T >, N > RTJmbInParams
Definition RTJmbInParameter.h:181
std::array< RTVstParam< T >, N > RTVstParams
Definition RTParameter.h:267
std::array< RTJmbOutParam< T >, N > RTJmbOutParams
Definition RTJmbOutParameter.h:208
std::array< VstParam< T >, N > VstParams
Definition ParamDef.h:513
std::array< JmbParam< T >, N > JmbParams
Definition ParamDef.h:525
std::array< RawVstParam, N > RawVstParams
Definition ParamDef.h:516
std::shared_ptr< JmbParamDef< T > > JmbParam
Definition ParamDef.h:522
std::shared_ptr< VstParamDef< T > > VstParam
Definition ParamDef.h:509
std::shared_ptr< RawVstParamDef > RawVstParam
Definition ParamDef.h:510
constexpr std::array< U, N > transform(std::array< T, N > const &a, F &&f)
Transforms an array containing elements of type T into an array containing elements of type U by appl...
Definition stl.h:41