loadUserPreset - strange behaviour...
-
@d-healey said in loadUserPreset - strange behaviour...:
I think you want to replace number with value.
If I replace number with value, HISE crashes when I compile the script
-
Even if I ditch the array
this = instant HISE crash:inline function onComboBox1Control(component, value) { switch(value) { case 1: Engine.loadUserPreset("asdf/Bass/BassLeveler"); break; case 2: Engine.loadUserPreset("asdf/Drums/DrumPump"); break; } }; Content.getComponent("ComboBox1").setControlCallback(onComboBox1Control);
-
@dustbro yeah HISE crashes like a 0.1 app when I use loadUserPreset
-
@Lindon :( Using the Preset browser floating tile works as expected... but my GUI only has room for a simple combo box.
not sure what I'm doing wrong -
@dustbro yeah must be some bug with the load preset function. But value is definitely right since number doesn't exist
-
@dustbro As Dave pointed out to me, using:
storeAllControlsAsPreset("abc",false);
and
restoreAllControlsAsPreset("abc");seems to be more reliable - try substituting those?
-
@Lindon I'll give that a try.
Is it required to use storeAllControlsAsPreset if the preset files already exist? -
@Christoph-Hart Is there an example of the CustomUserPreset tutorial that uses a combobox instead of the Viewport?
-
@dustbro dont think so you could just give the Restore option a try...
-
I'm having a go at making a custom preset browser, the first issue I've hit is
storeAllControlsAsPreset()
doesn't allow a folder structure with the file name, so all presets end up in the top level. Is there a known workaround for this?