Making a Scriptnode Sampler with MIDI
-
Hi all! Very basic scriptnode question: How can you make a sampler / rompler-style node in scriptnode using the fileplayer where each key on your MIDI keyboard maps to a different pitch of the sample? I'm assuming it's something like this, but I can't get it working:
-
@Casey-Kolb it seems you've created a ScriptFX network. You need to "Create New Processor > Scriptnode Synthesiser".
Then this network will work just fine. -
@Matt_SF Hmm, I still can't seem to get it to work. Do you have a snippet?
-
Does NoteNumber output in a range 0-127? If so you might need to add a math node to normalize it
-
@iamlamprey Seems like there might be some math involved for sure. I'm shocked there isn't an example somewhere for this. Also, I'm noticing that the "Root Frequency" doesn't actually change anything.
-
@Casey-Kolb here's a snippet for the scriptnode synth :
HiseSnippet 1368.3ocyX0sSibCE1S.ytgkts6psR6UUyEUprRrnDJcak5EDHjzFUBDwPQ6cHyLNfEyXO0iGfTzJ0q5qQeU5iPeS5dQumdrmYX7.AJDwRWPBhO1G6Oe946bbFHE9zjDgD4TemQwTjybXuQb0gsOjv3ndqibdJtOIQQktYhVaTLIIgFfbbl5GzBbpOMx7y6WYMRHg6SKEgP6JX9zMXQLUozAs9IVXXWR.cGVj0pWtUOeAusHTjB3YJbCTLw+HxAzMI5kUCibloS.SIjdJhhlfbldMQvHuCEmvyV+trD19gT8flHOXixD2UDFnQrVJp8grvfAE26DDxAOnzJLUlU3E39r.1ExKsFelYB2RMrsGN0pBuop.ul1vqgE7FCjbrfzzYP5YXOeIKVUNiFOOA2iCNmgDvraCkr0hb9SbaAr.tZwHxQztRXvEJL+aZzXAW3Ou56Glx8ULA2Uv2Tnnawm+Uyd1r0m8cy5d4oFNbryoOFoHLjJG6zZOs7lTbddZz9T4BtGSBSoWrP35W0lhudapsK2O6VasPAuGmo1Jlxut.ATtoB9zO2achhncD4xf0ESkJlFBNqSOFhpybK0wqSSNRIhg35q3yfnEQPZHQUMDRm2jOAXCp32zNGdBSMxNu5xwUSe6hqt4v9aKbeFd.S4e33waswfWvp8gFu4YoeBtyvgTeUIXmF28s2XJ48NTpW.krLNC4oAJ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Bz4al.cdyDny2NA57c2nN5WWlG0oqP.BFzIibyoCWy1aXVQ+KVKLJ2
Indeed, the Freq parameter doesn't seem to do anything, and there will be some math involved to make it work correctly, unless if you use a samplemap. In that case, you won't need to connect anything.
-
@Casey-Kolb T-shirt needed ! I'm an idiot : just create a samplemap of your sample layed down across the keyboard and load it in the file player, and you're done
This tread will be helpful, it is reated to loading samplemaps in scriptnode : https://forum.hise.audio/topic/5221/scriptnode-granulator/26
-
@Matt_SF yeah but still the single sample mode should repitch the sample when MIDI is enabled without having to adjust the freq ratio (the freq ratio is added on top of the repitch so you can modulate the pitch).
There‘s something funky going on and I‘m sure Mr. T-Shirt here has broken something along the way.
-
@Christoph-Hart Any update on this fix?