Sampler PitchModulation parameters



  • What is the proper way to script the Voice Start - Constant - PitchModulation on a sampler?
    I'm trying to use:
    but getting error "API call with undefined parameter 0 {SW50ZXJmYWNlfHw1NzU0MHwxNDUyfDMy}"

    const var Knob1 = Content.getComponent("Knob1");
    const var Constant = Synth.getModulator("Constant");
    
    inline function onKnob1Control(component, value)
    {
    	Constant.setAttribute(Constant.Intensity, value);
    };
    
    Content.getComponent("Knob1").setControlCallback(onKnob1Control);

  • administrators

    Just Constant.setIntensity(value); should work 🙂

    The intensity (and bypass state) are not parameters with a designated ID (which one might argue is a design flaw, but it's far too late for this to change), so there are dedicated methods for changing these.



  • @christoph-hart Excellent! That worked great!
    I may be noticing a bug when setting the Min / Max value of the knob.
    When I script the processor/parameter, it's component specific properties appear to match the PitchModulator value.
    When I set the Parameter Properties via the Interface Property Editor, the min / max don't match the PitchModulator value.
    It appears to be off by one decimal point?
    Scripted processor/parameter -4/+4 = -4/+4 on PitchModulator
    Parameter properties set via interface editor -0.4/+0.4 = -4/+4 on PitchModulator


  • administrators

    Actually I think it's a little more than 0.1 because it maps the range from -1.0 ... 1.0 to -12.0 ... 12.0 st.



  • @christoph-hart yup. you are correct


Log in to reply
 

1
Online

315
Users

914
Topics

5.9k
Posts

Looks like your connection to Forum was lost, please wait while we try to reconnect.