selecting files using a slider
-
@d-healey I read it but can't get it to work
-
Show me your code that uses the example from the docs and I'll be able to help you more from there.
-
@d-healey ```
const var ConvolutionReverb = Synth.getAudioSampleProcessor("ConvolutionReverb");
Engine.loadAudioFilesIntoPool(); // Load All IR into memory to be poolconst var irs = [];
irs[0] = "01 Large Ambience.wav";
irs[1] = "02 Medium Ambience.wav";
irs[2] = "03 Small Ambience.wav";
irs[3] = "12 Clear Ambience.wav";
irs[4] = "15 Percussion.wav";inline function onKnob1Control(component, value)
{
ConvolutionReverb.setFile("{PROJECT_FOLDER}irs[0]");
};
Content.getComponent("Knob1").setControlCallback(onKnob1Control); -
Looks like you're nearly there.
This line
ConvolutionReverb.setFile("{PROJECT_FOLDER}irs[0]");
You are only loading impulse number 0. You need to load the impulse selected by the knob, which you can get from the
value
parameter of the callback. So swapirs[0]
forirs[value]
You also need to concatenate the ir name onto the end of the string because the array cannot be part of the string.So the final line should look something like this:
ConvolutionReverb.setFile("{PROJECT_FOLDER}"+irs[value]);
-
@d-healey thank you, you're the man
-
@d-healey I put the names in an array, is there a way to display it?
-
@Jay I figure it out
-
@d-healey I have an array working fine, but I want to do now is to select anyone in the array and have a certain bottom to be on.
ex:
if I select 1 from array bottom 1 should do something, but if I select 8, bottom 2 should do something. -
Question on this ..
The PROJECT FOLDER is AUDIOFILES folder , but what if the user has to install the impulses in a folder of his choosing , will that still apply ? -
@lalalandsynth Impulses are embedded in the plugin aren't they?
-
yes, unless they go over over 50 mb with graphics right ?
I was under the assumption that if they went over 50mb with graphics you would have to install them seperately? -
This post is deleted! -
So I am using this code with a knob, knob set to discrete min 0 , max 2.
It seems to only load the AKG BX15 2.wav when the knob is at max ?
So , ignoring 0 and 1If I add an impulse , total 4 , set the max on the knob to 3 it will load the fourth one.
So it leaves out the first 2 ?
What am i missing here ?const var ConvolutionReverb1 = Synth.getAudioSampleProcessor("Convolution Reverb1"); Engine.loadAudioFilesIntoPool(); // Load All IR into memory to be pool const var irs = []; irs[0] = "Akg BX 15 1 Convert.wav"; irs[1] = "Akg BX 15 1.wav"; irs[2] = "AKG BX15 2.wav"; inline function onKnob1Control(component, value) { ConvolutionReverb1.setFile("{PROJECT_FOLDER}"+irs[value]); }; Content.getComponent("Knob1").setControlCallback(onKnob1Control);
-
@lalalandsynth said in selecting files using a slider:
It seems to only load the AKG BX15 2.wav when the knob is at max ?
So , ignoring 0 and 1That seems correct. When the knob is at max (2) it will load the file from your array in slot [2].
What are you wanting the outcome to be? -
But it does not load 0 and 1 , the impulse window is empty until it loads slot 2
-
@lalalandsynth check the script watch table. Is your array properly populated?
-
@lalalandsynth also, check your spelling. I see you have bx 15 for 0 and 1, and bx15 for 2 and 3
-
You were right about the spelling ! hehe
Still will not load the first one irs[0] = "Akg BX 15 1 Convert.wav";
The Array is populated and shows the first one .EDIT: Changed the name of the actual wave file from AKG BX 15 to AKG BX15 and then its loaded !
Thanks mate !
-
@lalalandsynth said in selecting files using a slider:
You were right about the spelling ! hehe
It's always something silly
-
Ok I am almost there with the configuration of my plugin.
Here is the layout . 3 buttons/panels , small, medium and large - 3 arrays of Impulses.
Each panel has a large knob where you can scroll through different arrays of IR´s.The selected panel and selected IR is saved as preset , if I select panel Large , IR 5 then that gets saved as a preset if needed, so all good on that front (took me some time to get that to work )
It looks like I have just one thing left to figure out.
Lets say I have IR 1 selected on panel 1 and IR 2 selected on panel 2 I would like them to switch the array accordingly , Problem I am having now is that when I switch from panel 1 to panel 2 I have to move the knob on panel 2 to make it switch . Hope I am making sense ?
I need the selection knob to be triggered when I switch panels.
Preset saving , correct IR shows panel all good !
Switching panels and moving knob, selects IR , all good.
Here is my problem , when I switch the panels and the knob is set to different IRs it does not trigger an IR selection until I move the knob . It should load the IR corresponding with the knob position.
I am sooo close ! hehe .
Can anyone help out here ?// Change Impulse with knob -knobSel //-------------------------------------------------- const var ConvolutionReverb1 = Synth.getAudioSampleProcessor("Convolution Reverb1"); Engine.loadAudioFilesIntoPool(); // Load All IR into memory to be pool const var irs = []; irs[0] = "Akg BX15 1 Convert.wav"; irs[1] = "Akg BX15 1.wav"; irs[2] = "AKG BX15 2.wav"; irs[3] = "AKG BX15 3.wav"; inline function onknobSelControl(component, value) { if (value) ConvolutionReverb1.setFile("{PROJECT_FOLDER}"+irs[value]); }; Content.getComponent("knobSel").setControlCallback(onknobSelControl); //Second Array Knobsel1 const var irs2 = []; irs2[0] = "Akg BX15 1 Convert.wav"; irs2[1] = "Akg BX15 1.wav"; irs2[2] = "AKG BX15 2.wav"; irs2[3] = "AKG BX15 3.wav"; inline function onknobSel1Control(component, value) { if (value) ConvolutionReverb1.setFile("{PROJECT_FOLDER}"+irs2[value]); }; Content.getComponent("knobSel1").setControlCallback(onknobSel1Control);
I am so used to the Flowstone workflow where I would just take the trigger from the Panel button and use that to trigger the array selection , not sure how to even approach this to be honest .
Wouldnt I need some kind of trigger from the panel selection button to tell it to check the index of the IR selection slider?