Forum
    • Categories
    • Register
    • Login
    1. Home
    2. Jeetender
    J
    • Profile
    • Following 0
    • Followers 0
    • Topics 3
    • Posts 21
    • Groups 0

    Jeetender

    @Jeetender

    1
    Reputation
    1
    Profile views
    21
    Posts
    0
    Followers
    0
    Following
    Joined
    Last Online

    Jeetender Unfollow Follow

    Best posts made by Jeetender

    • RE: This script processor has a network that consumes the parameters

      @dannytaurus said in This script processor has a network that consumes the parameters:

      @Jeetender Check the docs. Looks like you're missing an 's' at the end - setForwardControlsToParameters

      https://docs.hise.dev/scripting/scripting-api/dspnetwork/index.html#setforwardcontrolstoparameters

      Yes it was missing am 's' at the end, thank you. it works but gives out a warning in almost every script "Warning: 'local' used outside of callback/inline function, treating as 'var' "

      posted in General Questions
      J
      Jeetender

    Latest posts made by Jeetender

    • RE: Scripted radio buttons with the tabbed view

      It really feels weird, the Tabbed script i got from tabbed view snippet, is working in the snippet, and its working in my other project too, and the one iam currently, that same script is returning all the values on console, but nothing is updating on the UI, like the the button wont show the corresponding panel. its not a scripting error coz the script compiles ok and ive referenced every other project and settings.. what could be wrong, are backend files blocking ui or what.

      posted in General Questions
      J
      Jeetender
    • RE: Rms type or Cosine type Crossfade Curves

      @Lindon said in Rms type or Cosine type Crossfade Curves:

      @Jeetender eaiest way is ro use a scriptnode network and a xfade module...

      Yes, but iam not using DspNetwork. just trygin sumthing with the modules only.

      @griffinboy the script is ok, the knob is linear from min 0 to max 1, it only moves either knobs a few dbs +/- . I dont know, my tabs panels were working last night and now the panels wont change with buttons..

      It did work with a macro control, but still the curves

      posted in Scripting
      J
      Jeetender
    • RE: Rms type or Cosine type Crossfade Curves

      @griffinboy chatgpt or other bots aren't familiar with HISE coding yet i believe.. they just get confused with parameters.

      said in Rms type or Cosine type Crossfade Curves:

      @Jeetender

      This is pseudo code.
      It's something like this

      // Equal-power wet/dry crossfade (pseudocode)
      
      // knob range
      value = 0 to 127
      
      // normalize
      t = value / 127.0
      
      
      // equal-power law
      // sin/cos keep total power constant
      wet_lin = sin(t * PI * 0.5)
      dry_lin = cos(t * PI * 0.5)
      
      
      // linear → dB
      // dB = 20 * log10(gain)
      // log10(x) = ln(x) / ln(10)
      
      wet_db = 20 * ln(wet_lin) / ln(10)
      dry_db = 20 * ln(dry_lin) / ln(10)
      
      
      // clamp near zero (avoid -inf)
      if (wet_lin < 0.00001) wet_db = -100
      if (dry_lin < 0.00001) dry_db = -100
      
      
      // apply
      WET.Gain = wet_db
      DRY.Gain = dry_db
      
      
      
      /*
      Behaviour:
      
      t=0
      dry=1.0  (0 dB)
      wet=0.0  (-inf)
      
      t=0.5
      dry≈0.707 (-3 dB)
      wet≈0.707 (-3 dB)
      
      Summed signal power stays constant across the crossfade,
      so the centre position does not sound quieter.
      
      

      This is the kind of question that AI can help you understand.
      Ask chat gpt about it until you get why it works!

      posted in Scripting
      J
      Jeetender
    • RE: Rms type or Cosine type Crossfade Curves

      @David-Healey this works good but still the same issue, at 50% the volume is not constant.

      said in Rms type or Cosine type Crossfade Curves:

      @Jeetender What about setting the Gain of the SimpleGain where you want it and using a CC modulator to control the actual value (you can connect the Default value knob to a UI knob, you don't actually need to use a CC). Then you could set any shape you want using the modulation tables.

      611b63e8-5067-43ea-baa5-1cd17ee08750-image.png

      posted in Scripting
      J
      Jeetender
    • RE: Rms type or Cosine type Crossfade Curves

      @David-Healey no i did not, but the thing is there, i still have to balance between the send or wet with Dry. there is no direct wet dry balance in the modules...

      posted in Scripting
      J
      Jeetender
    • RE: Rms type or Cosine type Crossfade Curves

      @David-Healey iam just trying to create a wet dry balance between the two gain modules. iam not using scriptfx node. the earlier script moved the knobs in opposite direction but it was checking the peak volume, so at 50% the overall gain would just goo silent..

      err.jpg

      posted in Scripting
      J
      Jeetender
    • RE: Rms type or Cosine type Crossfade Curves

      @Lindon How

      const var wetdryknob = Content.getComponent("wetdryknob");
      const var FX_WET = Synth.getEffect("WET");
      const var FX_DRY = Synth.getEffect("DRY");
      
      inline function onWetDryControl(component, value)
      {
          local wetMix = value / 127.0;
          local dryMix = 1.0 - wetMix;
      
          local wetGain = Math.sin(wetMix * Math.PI * 0.5);
          local dryGain = Math.cos(dryMix * Math.PI * 0.5);
      
           wetGain = Math.max(wetGain, 0.0001);
          dryGain = Math.max(dryGain, 0.0001);
      
          local wetDb = Engine.getDecibelsForGainFactor(wetGain);
          local dryDb = Engine.getDecibelsForGainFactor(dryGain);
      
           FX_WET.setAttribute(FX_WET.Gain, wetDb);
          FX_DRY.setAttribute(FX_DRY.Gain, dryDb);
      }
      
      wetdryknob.setControlCallback(onWetDryControl);```
      posted in Scripting
      J
      Jeetender
    • RE: This script processor has a network that consumes the parameters

      @dannytaurus said in This script processor has a network that consumes the parameters:

      @Jeetender Check the docs. Looks like you're missing an 's' at the end - setForwardControlsToParameters

      https://docs.hise.dev/scripting/scripting-api/dspnetwork/index.html#setforwardcontrolstoparameters

      Yes it was missing am 's' at the end, thank you. it works but gives out a warning in almost every script "Warning: 'local' used outside of callback/inline function, treating as 'var' "

      posted in General Questions
      J
      Jeetender
    • Rms type or Cosine type Crossfade Curves

      here is a small code, i have a wet and and dry module in HISE, using simple gain, and there is a knob on the UI names wetdryknob, now this script works fine switching between wet and dry from -100 to 0db, but at 50% both the gain are at -50db, the curve is linear, iam not goo at maths, but the gain output should be constant and gain matched. how can i achieve it.

      const var wetdryknob = Content.getComponent("wetdryknob");
      const var FX1 = Synth.getEffect("WET");
      const var FX2 = Synth.getEffect("DRY");
      
      inline function onMasterKnobControl(component, value)
      {
          // Normalize value to 0–1 range
          local normValue = value / 127.0;
         
          // Map WET: 0 → -100dB, 1 → +18dB
          local wetGain = normValue * 127 - 0;
          
          // Map DRY: 0 → +18dB, 1 → -100dB (inverted)
          local dryGain = (1 - wetGain) - normValue * 0 - 101;
      
          FX1.setAttribute(FX1.Gain, wetGain);
          FX2.setAttribute(FX2.Gain, dryGain);
      }
         
      Content.getComponent("wetdryknob").setControlCallback(onMasterKnobControl);
      
      posted in Scripting
      J
      Jeetender
    • RE: This script processor has a network that consumes the parameters

      @Christoph-Hart Unknown function 'setForwardControlsToParameter'

      posted in General Questions
      J
      Jeetender