Trying to get a slider animation to follow the LFO mod



  • After racking my brains for the last week or so on this in another thread with no luck, I've thought of a possible third workaround for this job making a filmstrip slider (Knob1) to solve my animation problem and having that linked to the lfo modulation (LFOModulator1).

    I'm basically trying to get the slider to animate up and down on its own so that it reflects the behavior of the custom table in the lfo modulator (so frame 0 on the slider when the custom tables volume is 0, and frame 128 when the custom tables volume is all the way up)

    I have a similar thing in another project running gain reduction meters from the dynamics module reduction that works perfectly so I'm trying to adapt it to fit this, but it doesn't seem to work the same way trying to link the slider to the lfo modulation.

    I think I know where the problem is in the code but not sure what I need to replace it with. (I think 'GainModulation' needs to be replaced with something else. I've tried a few things but I'm still stuck 😞 )

    Can anyone please tell me what I need to change it to instead of "GainModulation"? ..or if there is something else that I've got wrong?

    Heres the code:

    const var LFOModulator1 = Synth.getEffect("LFOModulator1");
    
    const var Knob1 = Content.getComponent("Knob1");
    
    const var t = Engine.createTimerObject();
    t.setTimerCallback(function()
    {
        var v = LFOModulator1.getAttribute(LFOModulator1.GainModulation);
        
        v = Engine.getDecibelsForGainFactor(v);
        
        GainModulation.setValue(v);
    });
    
    t.startTimer(30);
    

    Snippet here if anyone can please help...

    HiseSnippet 1229.3oc0X0raaaDDdoj2Fa0pzjzbnGIL5AEzTEo5eZKJJBskrBD7ORnz0oE8P5JxURaL4tLjKkqRP.xgdnOFE8InuR4MnuAsyRRQsLQw1PMoHlGHzL6Ly9MyN+rT8CENznHQHxXsimFPQFeD1dJWNt0XBii51FY7Y3ioQRyNhPyc8holGv3vqN8Ls8XtzPyc3LeztSCHQQTWjgQ4GnzzXsUPIO+882k3Q3Nz4rPnSDLG5ALelbN29V6y775PboGy70jdSqtNBdKgmHFPYYbCT.w4TxH5QDkXkvHiOXOWlTDZKIRZDxXkcEtSsGKNimJ+IrH1.OphnIxFLTJ6NBOWEhUbQsFy7b6OKZDg.qzedrobZr413CYtrb9yiQ2HYAy4ZnGOLJcdvqoN7Zb4gmgF7VIEd2Da6DxBjyWQgsOD2kKogCIvQfN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vm3DJdjS5smUsSVMgC327juHeM7gJZy7qMiwMp2.4Ceg7ibbT2v3Kf3yh04KWBc1XIzYykPmsVBc1dIz4qVBc95yUG0eNwNwvftz7efQ+8RmWYjOpznL5eAj9CDyF
    


  • Bump Bump 🙂



  • @SteveRiggs the reference to the LFOMod seems to be wrong, if you want it declared as "generic script"

    const var LFOModulator1 = Synth.getModulator("LFOModulator1");
    

    or as Typed table script

    const var LFOModulator1 = Synth.getTableProcessor("LFOModulator1");
    


  • I don't know, if i got you right, but i think you need "LFOModulator1.getCurrentLevel()" to modulate the slider.

    HiseSnippet 1239.3oc0XEraaaDDcor2Fa0pzjzdnGIL5AEjTEpZG2XTTDEKaYHDYKgRGmVzCoqHWIs0j6RStRNJAAHG5g9YTzuf7ITf9Izuf7GzK8b6rKonHcUrMThKh4ABM6Nyruc12NyP0IT3PihDgHik2eb.EY7QX6wb4f5CHLNp4VHiOGuOMRZ1PDZto2PpYKFGd0nsosGykFZ9.NyGs43.RTD0EYXrvNJKMVdQj94ut+lDOB2gNcHD5.Ayg1h4yjSGsSsGx77ZPbo6y7yn8Z0Z5H30Edhg.JW.agBHNGR5S2inTq.FY7Aa6xjhPaIQRiPFKtovcr8.ww7X8OfEw55QUBUQ1fihGtgvyUgX0nn5CXdtclDMhPfW5LM1rPbr4Sw6xbYoiOMFcM8DlSsHa7vnvoAupYgm04GdFYf2hwv65XamPVfb5LJr8g3lbIMrGANBxBqXcQE9aCbcAnAWVwmbHsQHHjZQ40srts4csrt4WWpHbL.DgQjP0w+tB2gdDXaU07aL0TlJ8oxzQKuRNcVQY+ctSohY8xC4htJqmr7f80E9ABNHTdE8rZ6xZiDzeadefCVwIjBATEYIrc2eh5HKqTVVIhJ0CVm340EnJk6Mj6HYBd4aVp3yKUzDdTtZD3pbfTCfgggvx2hNh5o8mR6ru0vRsFGPfaCkGoz4EwnDVZIILdwKupNjMYoME78DRZa.CEedwkK9hhlmbpd8l4bpfSnvyCb4rlNdwNECKyG52kFdaXKC3MUQfzjmUheyrxrWZbhOqxnnf2jyjsCn72DWEkb.Cr1BInBTUp4rWMgyFmLAw.p4Uv5XLRC3j7.+9q9i+79nTiWL13RIFuOQgTksKg0+Nuw5GWhjfLdDdcqJ4eF0N3o8t2FU52dUq5Z4ipri8sVciFGrdrbT+io2Ro5FwxvqdYkQnG0bKk6gqUIaUX6GPCkLUj0XK5HHcW7czkwaQiNTJBzwhDxND8OynwSS2LuraswoBl+XsHIMvl8rI61Zu9Y+rJTk56qblAqL9tUFe+xCqEL4XrIn+GiyccAcLyUNHU6WcTsATV+ASSo+qt0P+2rTPtxItHaBTUUijI.9atLUprQ7Hlbb1pJWHYUOuv853NLoyfYi2By.uJp+ELdSpQUBucudPxvofcQbiuadKHM65kVmUAokR6kf4G3Q2YBTJkYfpmRSCHzVTORt32iyQ1PeesYzVQS9H3RWGgGI7jQ+ExukW37skOi1BNcJhZKY91PomePl8r3pwfDqt7pQ1IuFel3pQH8ngTtStHppQsl4NxdLYDsmHzOIQWx3eVsVz9vBkUy8oPxInmAmrqhsuPHGv38yz9WsW+a+RsVBQv1bUlJ2r52Y.IRU0DJEm020GFIE9SvxEUFeaHmqNkuwOfWesJ4me01uajQu6HDENmr1OQwMLSYAJ5664ohiQbJE8R.huAVmby7RS0taf0Ieu7.3qg6P3uG.2uULTBIz1kHCYPOV38F5aCeEqCEfJmS8TscaTPkzJV1RIq.jMk6pE9G3IYxpJYijIqNYx+WVCehSn3INwceqRmrjdDXey0eC9x3cUxlosciwVUrP9v2D+DGGUGHeADelsMe4bXypygMqMG1b24vl0mCa9p4vl6cp1n96HdvPnPXL+GFny1w0qLRKkZr.5eAte.LL�
    


  • @ulrik @toxonic Spot on fellas! Thank you. That makes much more sense now.

    🙂 Nice one


Log in to reply
 

8
Online

556
Users

2.1k
Topics

16.6k
Posts