Replacing ScriptModulationMatrix.getModValue in the new HISE
-
While the relocation of modulation values to LAF objects is a welcome upgrade, the old
ScriptModulationMatrix.getModValue(var component)
granted access to modulation values from anywhere, which made animated displays a breeze. You could simply use Slider 1's"getModValue"
in the LAF of Slider 2, and it would react to the manual+modulated values of Slider 1.Now I'm not sure what the best practice is for this sort of thing.- Linking two Sliders doesn't seem to cause any inheritance of modulation values- adding amatrixTargetId
to Slider 2 doesn't make a difference; it can't pick up obj.modulationActive or the respective values unless it's directly assigned- I tried sending modulation values from Slider 1's LAF into a registered variable, then to Slider 2's LAF. No luck.Is there a way to safely grab modulation values outside of their dedicated LAF objects?Modulator.getCurrentLevel()
does the job. -
@Goodflow
That's right. But how do you get the information about which modulation mode was selected? In other words, whether “scaled,” “unipolar,” or “bipolar” was selected?Perhaps via “modulationMatrix.getMatrixModulationProperties” or “modulationMatrix.getComponent,” or you could use “modulationMatrix.setConnectionCallback” and then write the information to a variable.