I've now got a weird problem when I use a 2nd instance of my 7 parameter control. It works fine for first instance where parameters start from index 0-6.
However, when I add the 2nd instance that starts at a different index i.e 8-15 it crashes because it thinks there are not enough parameters.
The plugin itself is registered to have 15 parameters which is enough for two instances plus one more control.
My plugin registers these 7 params for each instance in the constructor. Where the first parameter index is where to start.
Code:
AddAuxParam(mFirstParamIndex + kX); // x
AddAuxParam(mFirstParamIndex + kY); // y
AddAuxParam(mFirstParamIndex + kCF); // cf
AddAuxParam(mFirstParamIndex + kCS); // cs
AddAuxParam(mFirstParamIndex + kDF); // df
AddAuxParam(mFirstParamIndex + kDB); // db
AddAuxParam(mFirstParamIndex + kDFB); // dfb
Code:
Assertion failed: (idx > -1 && idx < mAuxParams.GetSize()), function GetAuxParam, file /Users/john/Development/cpp/wdl-ol/WDL/IPlug/IControl.cpp, line 145.
Is this a bug? Or should I actually be specifying aux params differently?