HISE Logo Forum
    • Categories
    • Register
    • Login

    Linking two 2 knobs to control same Module

    Scheduled Pinned Locked Moved Solved General Questions
    13 Posts 4 Posters 643 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • S
      Sawer @d.healey
      last edited by

      @d-healey Will check out thanks so much

      1 Reply Last reply Reply Quote 0
      • S
        Sawer @DanH
        last edited by

        @DanH Uhm..Will check now

        1 Reply Last reply Reply Quote 0
        • S
          Sawer @d.healey
          last edited by

          @d-healey Can fx.setAttribute(); get 2 parameter inside? or is there a function that can set values with a knob of 2 or more parameters in one instance? I've watched your video but it is relating only to 1 Parameter ("Gain" ) in three different fx modules, but how can I link two knobs changing two parameters of the same fx module? Thanks

          d.healeyD 1 Reply Last reply Reply Quote 0
          • d.healeyD
            d.healey @Sawer
            last edited by

            @Sawer

            how can I link two knobs changing two parameters of the same fx module?

            It's exactly the same, just instead of using 2 different effects use the same effect but change the attribute constant. For example a simple gain:

            SimpleGain1.setAttribute(SimpleGain1.Gain, -18.0);
            SimpleGain1.setAttribute(SimpleGain1.Balance, 0.5);
            

            Libre Wave - Freedom respecting instruments and effects
            My Patreon - HISE tutorials
            YouTube Channel - Public HISE tutorials

            S 1 Reply Last reply Reply Quote 0
            • S
              Sawer @d.healey
              last edited by

              @d-healey

              HiseSnippet 1166.3ocyW80iZaDDeMfuDHsQMQsuacOQTRo.20jJQiNmCNZQ4tKnvknHcJJcwdMrh065ZuNIz1SJO125mo9XeNeA5Gg9Insyt1b1bGvQPsUEAHO+c+MytyLq6GJbHQQhPjQ4SlFPPFej4fob431iwTNpWGjwMMOBGIIgVIr1eZ.NJh3hLLJ9MJFFkKgze9i81GyvbGRFKD54BpC4PpOUlwsu8ioLVWrK4DpeNs20tmif2VvDw.dJZVGEfclfGQNFqTqfIxXqCboRQ3.IVRh.c1W3NcvXwa3I5+bZDcHinHZfF.NJgMp8XJys+r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g.adbNgEoZBVPM8HgtthVAgADtqlP0dHUXCEsQpvFyD9exZ3icBEuxIY5h5rv00bf3lqeofxvam.zVmOTwzrds5p1czW43nNg94vo6EaSyMvlc1.a1cCr4K2.at+FXyC1.a9pUZi5ckdTrT3mz8BXz+.8vcCiC3X3zqt7D827bXGnK
              

              Ok tried this implementation, the code is not working. I'm just wondering what's missing?

              d.healeyD ulrikU 2 Replies Last reply Reply Quote 0
              • d.healeyD
                d.healey @Sawer
                last edited by

                @Sawer said in Linking two 2 knobs to control same Module:

                Ok tried this implementation, the code is not working. I'm just wondering what's missing?

                In your button callback you are just setting the value of the Delay attributes, this callback is only triggered when the button is clicked not when the knobs are moved.

                Libre Wave - Freedom respecting instruments and effects
                My Patreon - HISE tutorials
                YouTube Channel - Public HISE tutorials

                1 Reply Last reply Reply Quote 0
                • ulrikU
                  ulrik @Sawer
                  last edited by

                  @Sawer if I understand what you mean,
                  if button is on, you should be able to control both Left and Right Delay time with any of the knobs?

                  like this?
                  2knobslinked.gif

                  In both knobs callbacks, check if the button.getValue()

                  something like this

                  inline function onKnob2Control(component, value)
                  {
                  	Delay1.setAttribute(1, value);
                  	
                  	if (Button1.getValue())
                  	{
                  		Knob1.setValue(value);
                  		Knob1.changed();
                  	}
                  };
                  

                  and apply it to both callbacks

                  Hise Develop branch
                  MacOs 15.3.1, Xcode 16.2
                  http://musikboden.se

                  ulrikU 1 Reply Last reply Reply Quote 1
                  • ulrikU
                    ulrik @ulrik
                    last edited by ulrik

                    @ulrik Oh and by the way, it's recommended to use the attribute names instead of numbers.
                    You find them in Hise here:

                    I always have a floating window open for the "Module Browser"

                    floatingwindow.gif

                    so the changed code would be

                    inline function onKnob2Control(component, value)
                    {
                    	Delay1.setAttribute(Delay1.DelayTimeRight, value);
                    	
                    	if (Button1.getValue())
                    	{
                    		Knob1.setValue(value);
                    		Knob1.changed();
                    	}
                    };
                    

                    Hise Develop branch
                    MacOs 15.3.1, Xcode 16.2
                    http://musikboden.se

                    S 1 Reply Last reply Reply Quote 4
                    • S
                      Sawer @ulrik
                      last edited by

                      @ulrik Thanks so much man! Super clear explanation!

                      ulrikU 1 Reply Last reply Reply Quote 0
                      • ulrikU
                        ulrik @Sawer
                        last edited by

                        @Sawer 👍

                        Hise Develop branch
                        MacOs 15.3.1, Xcode 16.2
                        http://musikboden.se

                        1 Reply Last reply Reply Quote 1
                        • S Sawer has marked this topic as solved on
                        • First post
                          Last post

                        22

                        Online

                        1.7k

                        Users

                        11.8k

                        Topics

                        103.1k

                        Posts