ASPiK SDK
AAXPluginParameters.h
Go to the documentation of this file.
1 // -----------------------------------------------------------------------------
2 // ASPiK AAX Shell File: aaxpluginparameters.h
3 //
20 // -----------------------------------------------------------------------------
21 #pragma once
22 #ifndef RACKAFX_PARAMETERS_H
23 #define RACKAFX_PARAMETERS_H
24 
25 #include "AAX_CEffectParameters.h"
26 #pragma warning(disable : 4985) // --- 'ceil': attributes not present on previous declaration NOTE: for VS2008 only, see the google for more info
27 
28 #include "AAX_CAtomicQueue.h"
29 #include "AAX_IParameter.h"
30 #include "AAX_IMIDINode.h"
31 #include "AAX_IString.h"
32 #include "AAX_IEffectDescriptor.h"
33 #include "AAX_IComponentDescriptor.h"
34 #include "AAX_IPropertyMap.h"
35 
36 #include <set>
37 #include <list>
38 #include <utility>
39 #include <vector>
40 
41 // --- our plugin core object
42 #include "plugincore.h"
43 
44 // --- see AAX_ITransport.h before enabling this: performance hits!
45 // #define ENABLE_EXTRA_HOST_INFO
46 
47 // --- constants
48 const AAX_CTypeID PLUGIN_CUSTOMDATA_ID = 0;
49 
50 // --- special ProTools meter
51 const AAX_CTypeID GR_MeterID = 'grMT';
52 const unsigned int meterTapCount = 1;
53 
54 // --- setup context struct
56 class GUIPluginConnector;
58 class AAXMIDIEventQueue;
59 
72 {
73  GUIPluginConnector* guiPlugin_Connector = nullptr; // added nullptr 5.9.18
74  PluginCore* plugin_Core = nullptr;
75 };
76 
91 {
92  AAXPluginParameters* aaxPluginParameters;
93 };
94 
109 {
110  // --- audio
111  pluginPrivateData* privateData; // --- the RAFX Monolithic Parameters
112  float** inputBufferPtrs; // --- inputs buffer
113  float** outputBufferPtrs; // --- outputs buffer
114  int32_t* bufferLength; // --- buffer size (per channel)
115  float** grMeterPtrs; // --- Meter taps; currrently support one GR meter (have never seen more than 1)
116 
117 #ifdef WANT_SIDECHAIN
118  int32_t* sidechainChannel; // --- sidechain channel pointer
119 #endif
120 
121  // --- MIDI
122  AAX_IMIDINode* midiInputNode; // --- MIDI input node -> plugin
123  AAX_IMIDINode* midiTransportNode; // --- for getting info about the host BPM, etc...
124 
125  // --- params
126  int64_t* currentStateNum; // --- state value
127 };
128 
129 #define kMaxAdditionalMIDINodes 15
130 #define kMaxAuxOutputStems 32
131 
132 // --- NOTE: default here is 64 parameters; you should tweak this value to your final parameter count
133 // for the smallest size plugin; undetermined if this is more efficient or not.
142 #define kSynchronizedParameterQueueSize 64
143 
151 typedef std::pair<AAX_CParamID const, const AAX_IParameterValue*> TParamValPair;
152 
165 class AAXPluginParameters : public AAX_CEffectParameters
166 {
167 public:
169  virtual ~AAXPluginParameters();
170 
172  static AAX_CEffectParameters* AAX_CALLBACK Create();
173 
175  virtual AAX_Result UpdateParameterNormalizedValue (AAX_CParamID iParameterID, double iValue, AAX_EUpdateSource iSource );
176 
178  void AddSynchronizedParameter(const AAX_IParameter& inParameter);
179 
180 public:
181  // --- Overrides from AAX_CEffectParameters
182  virtual AAX_Result EffectInit();
183  virtual AAX_Result ResetFieldData (AAX_CFieldIndex inFieldIndex, void * oData, uint32_t iDataSize) const;
184  virtual AAX_Result GenerateCoefficients();
185  virtual AAX_Result TimerWakeup();
186 
188  static void AAX_CALLBACK StaticRenderAudio(AAXAlgorithm* const inInstancesBegin[], const void* inInstancesEnd);
189 
191  static AAX_Result StaticDescribe(AAX_IComponentDescriptor& outDesc);
192 
194  virtual AAX_Result GetCustomData(AAX_CTypeID iDataBlockID, uint32_t iDataSize, void* oData, uint32_t* oDataWritten) const;
195 
197  void updateHostInfo(AAXAlgorithm* ioRenderInfo, HostInfo* hostInfo);
198 
200  void ProcessAudio(AAXAlgorithm* ioRenderInfo, const TParamValPair* inSynchronizedParamValues[], int32_t inNumSynchronizedParamValues);
201 
203  void UpdatePluginParameters(const TParamValPair* inSynchronizedParamValues[], int32_t inNumSynchronizedParamValues);
204 
207 
220  {
221  // Using 4x the preset queue size: the buffer must be large enough to accommodate the maximum
222  // number of updates that we expect to be queued between/before executions of the render callback.
223  // The maximum queuing that will likely ever occur is during a preset change (i.e. a call to
224  // SetChunk()), in which updates to all parameters may be queued in the same state frame. It is
225  // possible that the host would call SetChunk() on the plug-in more than once before the render
226  // callback executes, but probably not more than 2-3x. Therefore 4x seems like a safe upper limit
227  // for the capacity of this buffer.
228  static const int32_t sCap = 4*kSynchronizedParameterQueueSize;
229 
230  TParamValPair* mElem[sCap];
231  int32_t mSize;
232 
233  SParamValList()
234  {
235  Clear();
236  }
237 
238  void Add(TParamValPair* inElem)
239  {
240  AAX_ASSERT(sCap > mSize);
241  if (sCap > mSize)
242  {
243  mElem[mSize++] = inElem;
244  }
245  }
246 
247  void Append(const SParamValList& inOther)
248  {
249  AAX_ASSERT(sCap >= mSize + inOther.mSize);
250  for (int32_t i = 0; i < inOther.mSize; ++i)
251  {
252  Add(inOther.mElem[i]);
253  }
254  }
255 
256  void Append(const std::list<TParamValPair*>& inOther)
257  {
258  AAX_ASSERT(sCap >= mSize + (int64_t)inOther.size());
259  for (std::list<TParamValPair*>::const_iterator iter = inOther.begin(); iter != inOther.end(); ++iter)
260  {
261  Add(*iter);
262  }
263  }
264 
265  void Merge(AAX_IPointerQueue<TParamValPair>& inOther)
266  {
267  do
268  {
269  TParamValPair* const val = inOther.Pop();
270  if (NULL == val) { break; }
271  Add(val);
272  } while (1);
273  }
274 
275  void Clear()
276  {
277  std::memset(mElem, 0x0, sizeof(mElem));
278  mSize = 0;
279  }
280  };
281 
282 private:
283  // --- see AAX_CMonolithicParameters in SDK
284  // these are identically declared and used with the AAX_CMonolithicParameters sample code
285  // this is the AVID method of synchronizing the playback-head to the controls
286  typedef std::set<const AAX_IParameter*> TParamSet;
287  typedef std::pair<int64_t, std::list<TParamValPair*> > TNumberedParamStateList;
288  typedef AAX_CAtomicQueue<TNumberedParamStateList, 256> TNumberedStateListQueue;
289 
290  typedef AAX_CAtomicQueue<const TParamValPair, 16*kSynchronizedParameterQueueSize> TParamValPairQueue;
291 
292  SParamValList GetUpdatesForState(int64_t inTargetStateNum);
293  void DeleteUsedParameterChanges();
294  std::set<std::string> mSynchronizedParameters;
295  int64_t mStateCounter;
296  TParamSet mDirtyParameters;
297  TNumberedStateListQueue mQueuedParameterChanges;
298  TNumberedStateListQueue mFinishedParameterChanges;
299  TParamValPairQueue mFinishedParameterValues;
300  int64_t mCurrentStateNum;
301 
302  // --- soft bypass flag
303  bool softBypass = false;
304 
305  // --- plugin core and interfaces
306  PluginCore* pluginCore = nullptr;
307  GUIPluginConnector* guiPluginConnector = nullptr;
308  PluginHostConnector* pluginHostConnector = nullptr;
309  AAXMIDIEventQueue* midiEventQueue = nullptr;
310 
312  uint32_t getChannelFormatForAAXStemFormat(AAX_EStemFormat format)
313  {
314  switch(format)
315  {
316  case AAX_eStemFormat_None: {
317  return kCFNone; }
318 
319  case AAX_eStemFormat_Mono: {
320  return kCFMono; }
321 
322  case AAX_eStemFormat_Stereo: {
323  return kCFStereo; }
324 
325  case AAX_eStemFormat_LCR: {
326  return kCFLCR; }
327 
328  case AAX_eStemFormat_LCRS: {
329  return kCFLCRS; }
330 
331  case AAX_eStemFormat_Quad: {
332  return kCFQuad; }
333 
334  case AAX_eStemFormat_5_0: {
335  return kCF5p0; }
336 
337  case AAX_eStemFormat_5_1: {
338  return kCF5p1; }
339 
340  case AAX_eStemFormat_6_0: {
341  return kCF6p0; }
342 
343  case AAX_eStemFormat_6_1: {
344  return kCF6p1; }
345 
346  case AAX_eStemFormat_7_0_SDDS: {
347  return kCF7p0Sony; }
348 
349  case AAX_eStemFormat_7_0_DTS: {
350  return kCF7p0DTS; }
351 
352  case AAX_eStemFormat_7_1_SDDS: {
353  return kCF7p1Sony; }
354 
355  case AAX_eStemFormat_7_1_DTS: {
356  return kCF7p1DTS; }
357 
358  case AAX_eStemFormat_7_1_2: {
359  return kCF7p1Proximity; }
360 
361  default: {
362  return kCFNone; }
363  }
364  return kCFNone;
365  }
366 
367 };
368 
381 {
382 public:
383  PluginHostConnector(AAX_IEffectParameters* _aaxParameters) {aaxParameters = _aaxParameters;}
384  virtual ~PluginHostConnector(){}
385 
391  virtual void sendHostMessage(const HostMessageInfo& hostMessageInfo)
392  {
393  switch(hostMessageInfo.hostMessage)
394  {
395  case sendGUIUpdate:
396  {
397  GUIUpdateData guiUpdateData = hostMessageInfo.guiUpdateData;
398 
399  for (uint32_t i = 0; i < guiUpdateData.guiParameters.size(); i++)
400  {
401  GUIParameter guiParam = guiUpdateData.guiParameters[i];
402 
403  std::stringstream str;
404  str << guiParam.controlID + 1;
405  AAX_IParameter* oParameter;
406  AAX_Result result = aaxParameters->GetParameter(str.str().c_str(), &oParameter);
407  if(AAX_SUCCESS == result)
408  {
409  oParameter->SetValueWithDouble(guiParam.actualValue);
410  }
411  }
412 
413  // --- clean up
414  for (uint32_t i = 0; i < guiUpdateData.guiParameters.size(); i++)
415  guiUpdateData.guiParameters.pop_back();
416 
417  break;
418  }
419  default:
420  break;
421  }
422  }
423 
424 protected:
425  AAX_IEffectParameters* aaxParameters;
426 };
427 
428 
441 {
442 public:
444  CustomViewController(ICustomView* _customViewIF) { customViewIF = _customViewIF; }
445  virtual ~CustomViewController() {}
446 
448  virtual void updateView()
449  {
450  if (customViewIF)
451  customViewIF->updateView();
452  }
453 
455  virtual void pushDataValue(double data)
456  {
457  if (customViewIF)
458  customViewIF->pushDataValue(data);
459  }
460 
462  virtual void sendMessage(void* data)
463  {
464  if (customViewIF)
465  customViewIF->sendMessage(data);
466  }
467 
469  void setCustomViewPtr(ICustomView* _customViewIF) { customViewIF = _customViewIF; }
470 
472  const ICustomView* getCustomViewPtr() { return customViewIF; }
473 
475  void clearCustomViewPtr() { customViewIF = nullptr; }
476 
477 
478 private:
479  ICustomView* customViewIF = nullptr;
480 };
481 
501 {
502 public:
504  GUIPluginConnector(AAX_IEffectParameters* _aaxParameters, PluginCore* _pluginCore){pluginCore = _pluginCore; aaxParameters = _aaxParameters;}
505 
508  {
509  for (customViewControllerMap::const_iterator it = customSubControllerMap.begin(), end = customSubControllerMap.end(); it != end; ++it)
510  {
511  delete it->second;
512  }
513  for (customViewControllerMap::const_iterator it = customViewMap.begin(), end = customViewMap.end(); it != end; ++it)
514  {
515  delete it->second;
516  }
517  }
518 
520  virtual void parameterChanged(int32_t controlID, double actualValue, double /*normalizedValue*/)
521  {
522  if(pluginCore)
523  pluginCore->guiParameterChanged(controlID, actualValue);
524  }
525 
527  virtual double getNormalizedPluginParameter(int32_t controlID)
528  {
529  // --- NOTE: this is the proper way for the GUI to get parameter values
530  std::stringstream str;
531  str << controlID + 1;
532  double param = 0.0;
533  AAX_Result result = aaxParameters->GetParameterNormalizedValue(str.str().c_str(), &param);
534  if(AAX_SUCCESS == result)
535  return param;
536 
537  return 0.0;
538  }
539 
541  virtual void setNormalizedPluginParameter(int32_t controlID, double value)
542  {
543  // --- NOTE: this is the proper way for the GUI to set parameter values
544  std::stringstream str;
545  str << controlID + 1;
546  aaxParameters->SetParameterNormalizedValue(str.str().c_str(), value);
547  }
548 
550  virtual void beginParameterChangeGesture(int controlTag)
551  {
552  if(aaxParameters)
553  {
554  std::stringstream str;
555  str << controlTag+1;
556  aaxParameters->TouchParameter(str.str().c_str());
557  }
558  }
559 
561  virtual void endParameterChangeGesture(int controlTag)
562  {
563  if(aaxParameters )
564  {
565  std::stringstream str;
566  str << controlTag+1;
567  aaxParameters->ReleaseParameter(str.str().c_str());
568  }
569  }
570 
572  virtual bool registerSubcontroller(std::string subcontrollerName, ICustomView* customViewConnector)
573  {
574  // --- do we have this in our map already?
575  CustomViewController* pCVC = nullptr;
576 
577  customViewControllerMap::const_iterator it = customSubControllerMap.find(subcontrollerName);
578  if (it != customSubControllerMap.end())
579  {
580  pCVC = it->second;
581  pCVC->setCustomViewPtr(customViewConnector);
582  }
583  else
584  {
585  pCVC = new CustomViewController(customViewConnector);
586  customSubControllerMap.insert(std::make_pair(subcontrollerName, pCVC));
587  }
588 
589  MessageInfo info(PLUGINGUI_REGISTER_SUBCONTROLLER);
590  info.inMessageString = subcontrollerName;
591  info.inMessageData = pCVC;
592 
593  if (pluginCore && pluginCore->processMessage(info))
594  return true;
595 
596  return false;
597  }
598 
600  virtual bool deRregisterSubcontroller(ICustomView* customViewConnector)
601  {
602  CustomViewController* pCVC = getCustomSubController(customViewConnector);
603  if (pCVC)
604  {
605  pCVC->clearCustomViewPtr();
606 
607  MessageInfo info(PLUGINGUI_DE_REGISTER_SUBCONTROLLER);
608  info.inMessageString = "";
609  info.inMessageData = pCVC;
610 
611  if (pluginCore && pluginCore->processMessage(info))
612  return true;
613  }
614 
615  return false;
616  }
617 
619  virtual bool registerCustomView(std::string customViewName, ICustomView* customViewConnector)
620  {
621  // --- do we have this in our map already?
622  CustomViewController* pCVC = nullptr;
623 
624  customViewControllerMap::const_iterator it = customViewMap.find(customViewName);
625  if (it != customViewMap.end())
626  {
627  pCVC = it->second;
628  pCVC->setCustomViewPtr(customViewConnector);
629  }
630  else
631  {
632  pCVC = new CustomViewController(customViewConnector);
633  customViewMap.insert(std::make_pair(customViewName, pCVC));
634  }
635 
636  MessageInfo info(PLUGINGUI_REGISTER_CUSTOMVIEW);
637  info.inMessageString = customViewName;
638  info.inMessageData = pCVC;
639 
640  if(pluginCore && pluginCore->processMessage(info))
641  return true;
642 
643  return false;
644  }
645 
647  virtual bool deRegisterCustomView(ICustomView* customViewConnector)
648  {
649  CustomViewController* pCVC = getCustomViewController(customViewConnector);
650  if (pCVC)
651  {
652  // --- clear it
653  pCVC->clearCustomViewPtr();
654 
655  MessageInfo info(PLUGINGUI_DE_REGISTER_CUSTOMVIEW);
656  info.inMessageString = "";
657  info.inMessageData = pCVC;
658 
659  if (pluginCore && pluginCore->processMessage(info))
660  return true;
661  }
662 
663  return false;
664  }
665 
667  virtual bool guiDidOpen()
668  {
669  if(!pluginCore) return false;
670  MessageInfo info(PLUGINGUI_DIDOPEN);
671  return pluginCore->processMessage(info);
672  }
673 
675  virtual bool guiWillClose()
676  {
677  if(!pluginCore) return false;
678 
679  for (customViewControllerMap::const_iterator it = customViewMap.begin(), end = customViewMap.end(); it != end; ++it)
680  {
681  it->second->clearCustomViewPtr();
682  }
683  for (customViewControllerMap::const_iterator it = customSubControllerMap.begin(), end = customSubControllerMap.end(); it != end; ++it)
684  {
685  it->second->clearCustomViewPtr();
686  }
687 
688  MessageInfo info(PLUGINGUI_WILLCLOSE);
689  return pluginCore->processMessage(info);
690  }
691 
693  virtual bool guiTimerPing()
694  {
695  if(!pluginCore) return false;
696  MessageInfo info(PLUGINGUI_TIMERPING);
697  return pluginCore->processMessage(info);
698  }
699 
701  virtual bool checkNonBoundValueChange(int tag, float normalizedValue)
702  {
703  if(!pluginCore) return false;
704 
705  // --- do any additional stuff here
706  // --- dispatch non-bound value changes directly to receiver
707 
708  return false;
709  }
710 
711 protected:
712  PluginCore* pluginCore = nullptr;
713  AAX_IEffectParameters* aaxParameters = nullptr;
714 
715  // --- this is for supporting the persistent interface pointer for the core object
716  // and is required by ASPiK Specifications
717  typedef std::map<std::string, CustomViewController*> customViewControllerMap;
718  customViewControllerMap customViewMap;
719 
722  {
723  for (customViewControllerMap::const_iterator it = customViewMap.begin(), end = customViewMap.end(); it != end; ++it)
724  {
725  if (it->second->getCustomViewPtr() == customViewConnector)
726  return it->second;
727  }
728 
729  return nullptr;
730  }
731 
733 
735  {
736  for (customViewControllerMap::const_iterator it = customSubControllerMap.begin(), end = customSubControllerMap.end(); it != end; ++it)
737  {
738  if (it->second->getCustomViewPtr() == customViewConnector)
739  return it->second;
740  }
741 
742  return nullptr;
743  }
744 };
745 
763 {
764 public:
767  : ioPacketPtr(0),
768  midiBuffersize(0)
769  {
770  pluginCore = _pluginCore;
771  };
772 
773  virtual ~AAXMIDIEventQueue(){}
774 
776  void setMIDIpackets(const AAX_CMidiPacket*& _ioPacketPtr, uint32_t& _midiBuffersize)
777  {
778  ioPacketPtr = _ioPacketPtr;
779  midiBuffersize = _midiBuffersize;
780 
781  }
782 
784  virtual unsigned int getEventCount()
785  {
786  return midiBuffersize;
787  }
788 
790  virtual bool fireMidiEvents(unsigned int sampleOffset)
791  {
792  while( (midiBuffersize > 0) && (NULL != ioPacketPtr) && ((ioPacketPtr->mTimestamp <= sampleOffset)))
793  {
794  const uint8_t uMessage = (ioPacketPtr->mData[0] & 0xF0); // message
795  const uint8_t uChannel = (ioPacketPtr->mData[0] & 0x0F); // channel
796 
797  midiEvent event;
798  event.midiMessage = (unsigned int)uMessage;
799  event.midiChannel = (unsigned int)uChannel;
800  event.midiData1 = (unsigned int)ioPacketPtr->mData[1];
801  event.midiData2 = (unsigned int)ioPacketPtr->mData[2];
802  event.midiSampleOffset = sampleOffset;
803 
804  // --- send to core for processing
805  if(pluginCore)
807 
808  ++ioPacketPtr;
809  --midiBuffersize;
810  }
811  return true;
812  }
813 
814 protected:
815  PluginCore* pluginCore = nullptr;
816  const AAX_CMidiPacket* ioPacketPtr;
817  uint32_t midiBuffersize = 0;
818 };
819 
820 #endif
821 
std::pair< AAX_CParamID const, const AAX_IParameterValue * > TParamValPair
Defines a parameter-value pair for the monolithic parameters AAX programming paradigm; this is very w...
Definition: AAXPluginParameters.h:151
Information that includes the message code as well as the message data.
Definition: pluginstructures.h:545
CustomViewController * getCustomViewController(ICustomView *customViewConnector)
Definition: AAXPluginParameters.h:721
The AAXPluginParameters object implements the monolithic parameters AAX plugin programming paradigm w...
Definition: AAXPluginParameters.h:165
uint32_t midiBuffersize
midi buffer size for each bunch of packets
Definition: AAXPluginParameters.h:817
virtual bool guiWillClose()
Definition: AAXPluginParameters.h:675
void setMIDIpackets(const AAX_CMidiPacket *&_ioPacketPtr, uint32_t &_midiBuffersize)
Definition: AAXPluginParameters.h:776
The CustomViewController is part of the safe ICustomView feature in ASPiK. The CustomViewController m...
Definition: AAXPluginParameters.h:440
virtual void updateView()
Definition: AAXPluginParameters.h:448
virtual bool processMIDIEvent(midiEvent &event)
process a MIDI event
Definition: plugincore.cpp:395
See AAX_CMonolithicParameters in SDK; this is part of the strict parameter synchronization in monolit...
Definition: AAXPluginParameters.h:219
void UpdatePluginParameters(const TParamValPair *inSynchronizedParamValues[], int32_t inNumSynchronizedParamValues)
called once per buffer process operation to update any parameters that changed during the buffer fill...
Definition: AAXPluginParameters.cpp:367
virtual void pushDataValue(double data)
Definition: AAXPluginParameters.h:455
AAX_IEffectParameters * aaxParameters
parent parameters; lifelong existence
Definition: AAXPluginParameters.h:425
GUIPluginConnector(AAX_IEffectParameters *_aaxParameters, PluginCore *_pluginCore)
Definition: AAXPluginParameters.h:504
AAX_IEffectParameters * aaxParameters
the parent object
Definition: AAXPluginParameters.h:713
#define kSynchronizedParameterQueueSize
This is the maximum size of the plugin-core&#39;s parameter list; make sure to adjust itg if your core ne...
Definition: AAXPluginParameters.h:142
virtual AAX_Result UpdateParameterNormalizedValue(AAX_CParamID iParameterID, double iValue, AAX_EUpdateSource iSource)
called when a parameter needs to be updated (aka it is "dirty") as part of the AAX monolithic paramet...
Definition: AAXPluginParameters.cpp:721
virtual bool deRregisterSubcontroller(ICustomView *customViewConnector)
Definition: AAXPluginParameters.h:600
uint32_t controlID
ID value.
Definition: pluginstructures.h:299
static AAX_Result StaticDescribe(AAX_IComponentDescriptor &outDesc)
static describe function that exists as an object member and is part of the monolithic programming pa...
Definition: AAXPluginParameters.cpp:593
static void AAX_CALLBACK StaticRenderAudio(AAXAlgorithm *const inInstancesBegin[], const void *inInstancesEnd)
static callback function that exists as an object member and is part of the monolithic programming pa...
Definition: AAXPluginParameters.cpp:555
void AddSynchronizedParameter(const AAX_IParameter &inParameter)
called to add parameters to the synchronized list; this is only called once during EffectInit( ) as p...
Definition: AAXPluginParameters.cpp:700
void clearCustomViewPtr()
Definition: AAXPluginParameters.h:475
virtual bool processMessage(MessageInfo &messageInfo)
For Custom View and Custom Sub-Controller Operations.
Definition: plugincore.cpp:335
virtual bool registerCustomView(std::string customViewName, ICustomView *customViewConnector)
Definition: AAXPluginParameters.h:619
virtual bool checkNonBoundValueChange(int tag, float normalizedValue)
Definition: AAXPluginParameters.h:701
CustomViewController(ICustomView *_customViewIF)
Definition: AAXPluginParameters.h:444
virtual AAX_Result ResetFieldData(AAX_CFieldIndex inFieldIndex, void *oData, uint32_t iDataSize) const
AAX Override.
Definition: AAXPluginParameters.cpp:755
void updateOutboundAAXParameters()
threadsafe update of outbound parameters (meter variables) for GUI.
Definition: AAXPluginParameters.cpp:881
Structure of data that is passed to GUI object once at creation time.
Definition: AAXPluginParameters.h:71
const AAX_CTypeID GR_MeterID
pro tools gr meter id
Definition: AAXPluginParameters.h:51
void ProcessAudio(AAXAlgorithm *ioRenderInfo, const TParamValPair *inSynchronizedParamValues[], int32_t inNumSynchronizedParamValues)
audio processing function; note that ALL algorithms point to this function so we have to decode chann...
Definition: AAXPluginParameters.cpp:446
virtual unsigned int getEventCount()
Definition: AAXPluginParameters.h:784
uint32_t midiMessage
BYTE message as UINT.
Definition: pluginstructures.h:487
Information about a GUI update message; this is for sending GUI control information from the plugin c...
Definition: pluginstructures.h:368
virtual bool deRegisterCustomView(ICustomView *customViewConnector)
Definition: AAXPluginParameters.h:647
AAXPluginParameters()
object constructor; this creates the ASPiK core and all of its required interfaces.
Definition: AAXPluginParameters.cpp:75
Custom interface so that GUI can pass information to plugin shell in a thread-safe manner...
Definition: pluginstructures.h:1219
virtual AAX_Result TimerWakeup()
AAX Override.
Definition: AAXPluginParameters.cpp:864
PluginCore * pluginCore
the core object
Definition: AAXPluginParameters.h:712
Custom View interface to allow plugin core to create safe communication channels with GUI custom view...
Definition: pluginstructures.h:1141
void updateHostInfo(AAXAlgorithm *ioRenderInfo, HostInfo *hostInfo)
called once per buffer process operation to set the host information structure for the core ...
Definition: AAXPluginParameters.cpp:402
virtual void parameterChanged(int32_t controlID, double actualValue, double)
Definition: AAXPluginParameters.h:520
const AAX_CMidiPacket * ioPacketPtr
array of packets
Definition: AAXPluginParameters.h:816
virtual void endParameterChangeGesture(int controlTag)
Definition: AAXPluginParameters.h:561
Definition: pluginstructures.h:397
AAXMIDIEventQueue(PluginCore *_pluginCore)
Definition: AAXPluginParameters.h:766
Double buffered queue for MIDI messages.
Definition: pluginstructures.h:1307
Processing structure; this is described in detail in Designing Audio Effects in C++ 2nd Ed...
Definition: AAXPluginParameters.h:108
virtual bool guiParameterChanged(int32_t controlID, double actualValue)
has nothing to do with actual variable or updated variable (binding)
Definition: plugincore.cpp:306
The GUIPluginConnector interface creates a safe message mechanism for the GUI to issue requests to th...
Definition: AAXPluginParameters.h:500
virtual void setNormalizedPluginParameter(int32_t controlID, double value)
Definition: AAXPluginParameters.h:541
std::map< std::string, CustomViewController * > customViewControllerMap
map of custom view controllers
Definition: AAXPluginParameters.h:717
const AAX_CTypeID PLUGIN_CUSTOMDATA_ID
custom data parameter number (we only need one)
Definition: AAXPluginParameters.h:48
Back-pointer to the parameters; this is described in detail in Designing Audio Effects in C++ 2nd Ed...
Definition: AAXPluginParameters.h:90
virtual double getNormalizedPluginParameter(int32_t controlID)
Definition: AAXPluginParameters.h:527
virtual AAX_Result EffectInit()
AAX Override.
Definition: AAXPluginParameters.cpp:157
virtual AAX_Result GenerateCoefficients()
AAX Override.
Definition: AAXPluginParameters.cpp:654
void * inMessageData
incoming message data (interpretation depends on message)
Definition: pluginstructures.h:559
The AAXMIDIEventQueue interface queues incoming MIDI messages and blasts them out during the buffer p...
Definition: AAXPluginParameters.h:762
std::vector< GUIParameter > guiParameters
list of updates
Definition: pluginstructures.h:373
virtual bool registerSubcontroller(std::string subcontrollerName, ICustomView *customViewConnector)
Definition: AAXPluginParameters.h:572
uint32_t midiData2
BYTE data 2 as UINT.
Definition: pluginstructures.h:490
void setCustomViewPtr(ICustomView *_customViewIF)
Definition: AAXPluginParameters.h:469
CustomViewController * getCustomSubController(ICustomView *customViewConnector)
Definition: AAXPluginParameters.h:734
virtual bool guiDidOpen()
Definition: AAXPluginParameters.h:667
The PluginCore object is the default PluginBase derived object for ASPiK projects. Note that you are fre to change the name of this object (as long as you change it in the compiler settings, etc...)
Definition: plugincore.h:43
virtual ~GUIPluginConnector()
Definition: AAXPluginParameters.h:507
virtual void sendMessage(void *data)
Definition: pluginstructures.h:1162
virtual AAX_Result GetCustomData(AAX_CTypeID iDataBlockID, uint32_t iDataSize, void *oData, uint32_t *oDataWritten) const
note the data that is transferred to GUI; the core is ONLY used for initialization and then it is unu...
Definition: AAXPluginParameters.cpp:131
Information that defines a single GUI parameter&#39;s possible values and ID.
Definition: pluginstructures.h:291
virtual bool fireMidiEvents(unsigned int sampleOffset)
Definition: AAXPluginParameters.h:790
PluginCore * pluginCore
core
Definition: AAXPluginParameters.h:815
base class interface file for ASPiK plugincore object
double actualValue
actual value
Definition: pluginstructures.h:300
Information from the host that is updated on each buffer process cycle; includes BPM, time signature, SMPTE and other data. The values in the stock structure are consistent across most APIs, however others may be added (commnted out here)
Definition: pluginstructures.h:729
virtual void updateView()=0
std::string inMessageString
incoming message data as a std::string (interpretation depends on message)
Definition: pluginstructures.h:562
Custom interface to send the plugin shell a message from plugin core.
Definition: pluginstructures.h:1289
The PluginHostConnector implements the IPluginHostConnector interface for the plugin shell object...
Definition: AAXPluginParameters.h:380
static AAX_CEffectParameters *AAX_CALLBACK Create()
creation mechanism for this object
Definition: AAXPluginParameters.cpp:59
virtual void sendHostMessage(const HostMessageInfo &hostMessageInfo)
process a message; by default it processes sendGUIUpdate to safely send a parameter change event but ...
Definition: AAXPluginParameters.h:391
virtual void beginParameterChangeGesture(int controlTag)
Definition: AAXPluginParameters.h:550
const ICustomView * getCustomViewPtr()
Definition: AAXPluginParameters.h:472
customViewControllerMap customSubControllerMap
map of custom sub-controllers
Definition: AAXPluginParameters.h:732
virtual void pushDataValue(double data)
Definition: pluginstructures.h:1152
const unsigned int meterTapCount
number of gr meters (we&#39;ve only ever seen one on any AVID surface/SW)
Definition: AAXPluginParameters.h:52
virtual void sendMessage(void *data)
Definition: AAXPluginParameters.h:462
virtual bool guiTimerPing()
Definition: AAXPluginParameters.h:693
virtual ~AAXPluginParameters()
object destructor; this destroys the ASPiK core and all of its required interfaces.
Definition: AAXPluginParameters.cpp:110
Information about a MIDI event.
Definition: pluginstructures.h:449