Add CC modulator to container
-
Would this be possible? I'm thinking particularly it would be good to be able to add CC11 and CC7 control to modulate the master chain container's gain parameter. I can do this via scripting but without some kind of lag function it wouldn't be as good as the built in modulators.
-
Yeah, sure, the problem is right now that Containers don't process incoming events in their modulator chains and I have to dig around a bit to make this work out of the box.
There is a workaround which I think may seem like wizardry to you :), but you can also script modulators and use a few ready made DSP building blocks to achieve something like this:
HiseSnippet 1508.3oc4X80aTaDD2NIVzbvQKRTo9PeX0o9vEQpy4DnTHBH+AB5.Rxo3zTTqpn6YuWtsmsW20qS3.wmf9knu0uNUpeQ3aP6r6Zisy4lbIEZenVIR1yNy3eyr+lYVe83LORRBiaXd48GGSLLuhk63HwvMGhoQFceng4Us1FmHHbjVzFiiwIIDeCSyYerTf47yYntd6C1.Gfi7HEhLLNfQ8HOiFREER+w0dJMHXKrOYeZXIsu4Zc8XQaxBXo.dl0piQL1aD9PxNXoZyXYbDkbbhgYGqUV1lOxo+qV2Ft13N236518ND31t11iF8SqbCkb80F11FdobNIRb.Xtgok4eBWlVOxmJXbWAVP.eN2FL+wtCYGGoe0GPSn8CHxGbLbALoEuEKvWF7x6M1bHMvuWdJLw.7cuhD5r5D50s1l5Sem7hD6mnV.UXQ4Tq4LmF7btfvyrD7lSCuqY45wowhhUjX6JVaxhDbVP.oJtzJaLyuXZA6UIBzQXNRSPjrAWhPRUtGRQhrOjH1l4mFfgHocqLdjTOjVwVKrZyFMaLHMxSPYQHVzNLAY2n1Kz30MluwalXkACpaoBrpWkNn81Pr.LGIBJVcmzv9RcP26dnauPyFy+Z3+4WZIzSRgHIgHPhgDDVH3z9oBBhMPIHTtMEmmejlbx.1Frc8byZ2YQTsu9CvAoD3suDxY4aa2YgUaL+apFHx5A9oDgsiTQvhPVGbUtdv1cUxxkmNxBrAJfphRJxh5FQE6FSxJBx2OlPxfAkEUDhkkpBlZTqPzoyVM1TiO3tIosPwSNwpbEkbKIaAHwUg41U5rDpXb4NVe3Kyrz38yyJyjIkCvbJNpnxPg8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peYq4gu8CdF4jO+Wlaj+pCuvySlr+RH6TuEKetsXkysE27bawsN2V7UmaKt841hu9TrPNPY8TAKTW5YX7WHe5viF
It uses a MIDI ScriptProcessor and a scripted TimeVariantModulator that applies smoothing by using the
smoothed_gainer
DSP module.This pretty much opens the box of pandora once you understand how it works :)
The Javascript code of the modulator is running directly in the audio thread, so be careful (if you mistype something it can get extremely loud)
PS: Just noticed that the smoothing time parameter isn't working :)
-
Oh this looks interesting, I'll have to spend some time with the DSP stuff at some point
-
FYI, I've just added support for MIDI Control modulators in the Gain chain of Containers.
There's one little drawback: its not sample accurate, because it will be only called once per block (so depending on the buffer size once every 2 - 10 ms). This is required to avoid overhead when rendering containers. However there are almost none MIDI controllers that emit data with a higher frequency and the timing errors should be neglectible since you probably run it through a smoother anyway...
-
Excellent!