The Missing Piece of the HISE VI Puzzle: Continuous Per-Event Modulation
-
@aaronventure yes exactly.
-
@Christoph-Hart perfect
-
@aaronventure Alright, I've written a few tools with this concept:
- a
GlobalRoutingManager.setEventData(eventId, slotIndex, value)
API method where you can set up to 16 double values per event ID and - get them with
GlobalRoutingManager.getEventData(eventId, slotIndex)
(if the data hasn't been set yet it will return undefined.
This basically replicates our existing Javascript helper class but in C++ and globally accessible through the global routing manager. But then it gets interesting:
- a voice start modulator that will query the given data slot and resort to a default value if not set (so you don't need to use the script voice start modulator for just passing on that value to whatever target anymore).
- a
routing.event_data_reader
node that will polyphonically read the event data and send it as scriptnode modulation connection. There are two modes available, one only reads and sends the value when the node processes the incoming note on message (to replicate voice start modulation like behaviour) and the other one listens for changes from the last event ID and outputs a time-varying modulation signal. - a
routing.event_data_writer
node that will write an incoming value into the data slot. This is polyphonic and timevarying, so you can basically send the envelope output from one scriptnode envelope to another (or create the data however you like). The update rate is tied to the buffer size though (because that's how the modules are processed one after another).
I'll clean it up a bit tomorrow and write some docs, but it looks promising.
- a
-
@Christoph-Hart said in The Missing Piece of the HISE VI Puzzle: Continuous Per-Event Modulation:
The update rate is tied to the buffer size though (because that's how the modules are processed one after another).
What does this mean for wrapping stuff up in frame/block nodes? Will it just shout about rate mismatch like the midi node when you try to place it within a block node?
-
@aaronventure no, the update rate is simply the buffer size as this is the rate that the sound generators are able to talk with each other.
-
@Christoph-Hart so on higher buffer sizes, you get lower resolution streams?
Alright, it's then important to highlight it, as this warrants like 20ms smoothing at the lowest for consistency. Can the read nodes have smoothing built in? it'll be necessary anyway, this would just make it less of a mess.
-
You can use Engine.setMaximumBufferSize() to limit the buffer length to 64 or something then you get a guaranteed update rate of 1,5ms if that‘s what you need.
The nodes will not have any smoothing as you can simply add a smoothed parameter node, but the event data envelope (which is a polyphonic HISE envelope that automatically reads out the values from the given slot will have a smoothing parameter (like the LFO).
-
@Christoph-Hart Ah, good to know, I didn't know I can hard limit the buffer size for the plugin.
Yes, smoothing parameter/control is what I meant. Hiding smoothing inside the actual readout would be naughty.
-
@aaronventure Alright, the feature is pushed now (alongside with the documentation for each thing).
I've also added a bunch of snippets to the browser that demonstrate various use cases (Custom Data Event 101/102/103).
Let me know if you find some quirks.
-
Does that solve this request? https://forum.hise.audio/topic/9501/message-event-flags-or-meta-data?_=1716378593963
-
@d-healey yup. You can now write 16 number values to a slot using an event ID and pick it up later either using scripting, a new modulator or nodes in scriptnode.
-
@Christoph-Hart Cool, have the docs been pushed?
-
@d-healey It also solves Per-event routing: https://forum.hise.audio/topic/9625/per-event-routing?_=1716386003580
-
This is still broken because 0 cannot be sent:
-