Arpeggiator Presets
-
@d-healey I can get the values into an array. I then need to get them into an object and then back into the sliderpacks....
-
I can get the values into an array.
Can you get them out of the array and back into the sliderpack (ignoring the object part at the moment)?
-
@d-healey yup
-
@DanH Can you access an array that is inside an object?
-
@d-healey yup
-
@DanH So which part are you missing?
-
@d-healey how to fit it into the system I'm using to save the arp presets. Let me have another go
-
@DanH Make a simple snippet that saves one slider pack into an array and writes it to a json file and reloads it. That will give us something to work with.
-
@d-healey Well I think my issue is in the setControlValues callback below. I have all the data correctly stored in the json file now, it's just loading it back into the SliderPacks that's the issue. The knobs all work fine
inline function getControlValues3() { return { "ARPNOTESNUMDATA" : ARPNOTESNUM.getValue(), "ARPSPEEDDATA" : ARPSPEED.getValue(), "ARPSHUFFLEDATA" : ARPSHUFFLE.getValue(), "ARPSHUFFLE1DATA" : ARPSHUFFLE1.getValue(), "ComboBox1DATA" : ComboBox1.getValue(), "SliderPack4ARPDATA" : SliderPack4SAVEData, "SliderPack5ARPDATA" : SliderPack5SAVEData }; } inline function setControlValues3(data) { ARPNOTESNUM.setValue(data.ARPNOTESNUMDATA); ARPNOTESNUM.changed(); ARPSPEED.setValue(data.ARPSPEEDDATA); ARPSPEED.changed(); ARPSHUFFLE.setValue(data.ARPSHUFFLEDATA); ARPSHUFFLE.changed(); ARPSHUFFLE1.setValue(data.ARPSHUFFLE1DATA); ARPSHUFFLE1.changed(); ComboBox1.setValue(data.ComboBox1DATA); ComboBox1.changed(); for (i = 0; i < data.SliderPack4ARPDATA.length; i++) { SliderPack4[i].setSliderAtIndex(i, data.SliderPack4ARPDATA[i]); SliderPack5[i].setSliderAtIndex(i, data.SliderPack5ARPDATA[i]); } }
I can make a snippet but it's gonna take me a sec.
-
-
@DanH said in Arpeggiator Presets:
I can make a snippet but it's gonna take me a sec.
Yeah make a simple snippet, one slider pack, one object, one array, etc.
I'm going to have dinner now so I'll take a look when I get back.
I think a much simple solution might be to use a sliderpackdata object (although I've never tested writing it to a file I think it should work).
-
@d-healey @DabDab Ok got it working thanks to @Casey-Kolb (it was a silly error!).
Here's a snippet for those interested, it's a bit messy but you can see how the sliderpack is saved and reloaded (as well as knobs). I figure you can use this as a base for your own user preset system (@ulrik also made a good one too)
HiseSnippet 4059.3oc6b0DaabbEdWIsxhxV1xNIMosAoKHRCnRrY3RJYIVGWQJIJGESIRKJIaWGi3UjCE2nk6Ru6RYKmZ.en8RA5ghhBDfdnAHG5kdH8V6gB3K8TQAJR6wh1jhVfBjFfbo.sGJbm+1cm8OpkxNMNMjFVR6Lu4Mu226Mu48lcjpZnWGXZpavwmXi86.33OlPs80rZsXKYEMtUVhi+3BEWuZshaUp1ZqTsJ2B62Q1zDzfime3KfngOwHbbb23IO+eX9EjUk0pCnMU3Cuy2Y9szUpCJqzVwh1J7S0BWTQUcY4FfMTZCbae5BqTWWaQcU8tP4YXgLbcjquq7Nf0jQjMj.G+nkZnXoaTyR1BXxwOxB5M1uVK8aoQneKESksUAnGj3pAYDo4k0UafjXTqbK1RQsQUa81jCxkptnvvDT3IEVUoghS6tnwj3NDcGAKdvOTuDOoCV7xDl3MDi3MBQ7NoPs5FJcrb6AIaGUXEMKfQSYnIfUrHzxMzu9IEVTGRglU51x6BV1.9fyHRIIkIyoEmMSloN2Dii9GzVXZItmrgXQiNfc1QQFpZRhmWD6fjdGfkGLJURVxRh3hKGpopz.XTEZNQLvVJfrXQ81cz0fOjJICM9F8E0z2N5wg6MjQjsmiHaRhd5NlEVuxkqUZ8HGEs+.iql7dfpF.SfUzplCI9wEmNpzwRA1bLXAkRebhzGZkxF5HZijQ9IjpOJZpJZ.wlc0piXuntFcYOhKF5popayhSCmO0tfolX72ZhwSPQkzlP2baRI8CYaBxjsfg9sLAFkWtR5N5c5pBWcP5nrhoUJLgATOOLD6SJB+3RVZ3+2BMOtc5WyPjjJoE31VIOsXx5sz0MAhZvtSmNMUquK9qgCTT8O4TH9PkjEkUU2F5glxO7PX2K+xhKAZBwQSQHgh0I8AePqgXc5PMEapaH1g3vrMAYlXbjX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NyLyIIkKS94jld5Y3ZqzP4MpWGcsuNCLG7PFdVlgmMS574xjIaNo74xMS9oOngWaiRUcG9zSmNW1bylWZlL4xm4rYOfYeXgq3byBExjNyAQ8U6CpGR3yHhQ+ldTrqkdaRgUvFph+SBCbQOSjUt+qvVzEy
-
@DanH This only works on PC - or
It does not work on my Mac
-
@MikeB well it was created on a Mac so… ️
-
@MikeB This is often an issue with the permission settings of a folder. Very occasionally Macs can have weird permissions on the Application Support folders, so you need to update your folder to be Read / Write in order for this to work properly.
-
@DanH Thank You Dear :) Snippets are the best Learning material for Me :)
-
@DanH Ok - Then can you tell me where the AppData folder is?
Where are the presets stored?
-
@MikeB The AppData folder is the folder your plugin uses for essential data (presets, license key, link to samples etc). It should be in ~Library/Application Support/Your Plugin Manufacturer Name/Plugin Name/
Within that folder (via the script) you can create whatever folders you like. For simplicity I have scripted it to be Data/Arp and the files will be .arp files.
One quirk is that when using HISE it seems to need the actual plugin AppData (~Library/etc) folder there in order to read and write the presets. It doesn't use the HISE project folder as it does for the other AppData files. Am I doing it wrong anyone?
-
@DanH Ok - Thank you - now I think I understand.
It only works in the compiled plug-in, not in the backend - right? -
"One quirk is that when using HISE it seems to need the actual plugin AppData (~Library/etc) folder there in order to read and write the presets. It doesn't use the HISE project folder as it does for the other AppData files. Am I doing it wrong anyone?"
-- yes thats correct if you want to reference the appdata folder then HISE itself will do that as well as the plug-in.