HISE Logo Forum
    • Categories
    • Register
    • Login

    Range of slider linked to container gain

    Scheduled Pinned Locked Moved General Questions
    5 Posts 2 Posters 682 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.
    • d.healeyD
      d.healey
      last edited by

      I want to control the gain of a container using a slider. To do this using the processor ID and parameter ID dropdown method in the interface designer I need to set the range of the slider to 0-1. However this doesn't tie with the range of the container's slider -100-0. This would be fine except I'd like to display the correct dB value on the slider (I'm using the native slider control).

      I could do this via scripting using the conversion function and everything would match but it would be nice if the processor ID system could be used for this purpose.

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

      1 Reply Last reply Reply Quote 1
      • Christoph HartC
        Christoph Hart
        last edited by

        This can't be changed without breaking everything, so it's not an option unfortunately. Use a simple gain instead, this gets you also a crackle free movement.

        d.healeyD 1 Reply Last reply Reply Quote 1
        • d.healeyD
          d.healey @Christoph Hart
          last edited by

          @christoph-hart Darn, no problem. I came up with another solution, hide the slider text and place a label over it with custom text. I don't want to use a simple gain for this as the idea is to set the volume of each articulation and then just leave them so the crackle shouldn't be a problem.

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

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

            Actually this won't work I just realised. This is related in a way to my other thread about set value >> parameters. If I have the control linked to a parameter I can't update a label when it's moved because the callback won't be triggered :(

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

            1 Reply Last reply Reply Quote 0
            • Christoph HartC
              Christoph Hart
              last edited by

              I guess you have to write a control callback for the slider then and use Engine.getGainFactorForDecibels to convert to the required 0...1 range.

              1 Reply Last reply Reply Quote 1
              • First post
                Last post

              51

              Online

              1.7k

              Users

              11.7k

              Topics

              101.9k

              Posts