selecting files using a slider



  • @d-healey ```

    const var ConvolutionReverb = Synth.getAudioSampleProcessor("ConvolutionReverb");
    Engine.loadAudioFilesIntoPool(); // Load All IR into memory to be pool

    const 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 swap irs[0] for irs[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 1

    If 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 1

    That 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
    load.gif



  • @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 !
    preset.gif

    Switching panels and moving knob, selects IR , all good.
    preset 2.gif

    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.
    preset 3.gif

    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?



  • Solution , courtesy of @Lindon

    HiseSnippet 1466.3ocsX0uaaaCDmJIps1adXEaO.D9urwxbj+JsMEcyKeUj00Di5thsALzRKQayFYROI5jFDDf7nrGk9Hs2fsiTRVzN1xIFKJ.wl73c+9w6Nd9nZGHboggh.jUt2dwHJx5Ks6bAWNXuADFGcz9HqGYKogRm5ncuXDILj5grrV+kJoV41.oe9mebWhOg6RSmBgdmf4R+E1PlLc11sdEy2+PhG8srgFqtQqibE78D9hw.SV21AMh3dJoO8XhZYqYirdvAdLoHnij.zAYswtBuK5LPbNOZ8uiEx55SUCph5.FJZ5CE9dJFqlEs2.luW6jcbHBrR6z8+5Q6+u090LO1j4S8CesV.NUCS+g0ZYQuplzy41SOKC5sQD8drcG2.1HYpDE29B6i3RZPOBDBLoUzZQq0Mm8dBXEbYkgjSoGF.ClnQoscb1D2zwo7y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