HISE Logo Forum
    • Categories
    • Register
    • Login

    Linear Slider - Prevent value jumping to mouse click point

    Scheduled Pinned Locked Moved General Questions
    9 Posts 5 Posters 94 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.
    • DanHD
      DanH
      last edited by

      I've drawn myself a modwheel in laf using drawLinearslider but the behaviour isn't right as wherever you click the mouse on the slider the value jumps to that point. I want behaviour like a rotary knob, click and drag to change value... Any ideas?

      DHPlugins / DC Breaks | Artist / Producer / DJ / Developer
      https://dhplugins.com/ | https://dcbreaks.com/
      London, UK

      ustkU 1 Reply Last reply Reply Quote 0
      • ustkU
        ustk @DanH
        last edited by

        @DanH It shouldn't be the case if the slider mode is set to knob

        Hise made me an F5 dude, browser just suffers...

        DanHD 1 Reply Last reply Reply Quote 0
        • DanHD
          DanH @ustk
          last edited by

          @ustk yeah but then the laf doesn't work....

          DHPlugins / DC Breaks | Artist / Producer / DJ / Developer
          https://dhplugins.com/ | https://dcbreaks.com/
          London, UK

          ustkU 1 Reply Last reply Reply Quote 0
          • ustkU
            ustk @DanH
            last edited by

            @DanH why is that? In knob mode you should be able to draw anything, like faking a vertical slider

            Hise made me an F5 dude, browser just suffers...

            DanHD 1 Reply Last reply Reply Quote 0
            • DanHD
              DanH @ustk
              last edited by

              @ustk that's what I thought too 😆

              DHPlugins / DC Breaks | Artist / Producer / DJ / Developer
              https://dhplugins.com/ | https://dcbreaks.com/
              London, UK

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

                @DanH drawRotarySlider

                Free HISE Bootcamp Full Course for beginners.
                YouTube Channel - Public HISE tutorials
                My Patreon - HISE tutorials

                DanHD 1 Reply Last reply Reply Quote 0
                • DanHD
                  DanH @d.healey
                  last edited by

                  @d-healey @ustk oh hang on, I wasn't doing both, just one or the other 😆

                  DHPlugins / DC Breaks | Artist / Producer / DJ / Developer
                  https://dhplugins.com/ | https://dcbreaks.com/
                  London, UK

                  ChazroxC 1 Reply Last reply Reply Quote 2
                  • ChazroxC
                    Chazrox @DanH
                    last edited by

                    @DanH

                    if (obj.style == int) 
                    {
                    do laf
                    }
                    if (obj.style == int)
                    {
                    do another laf
                    }
                    
                    
                    Christoph HartC 1 Reply Last reply Reply Quote 0
                    • Christoph HartC
                      Christoph Hart @Chazrox
                      last edited by

                      Yes, it's a feature not a bug of the linear slider style to pick up the value when you click on it. If that is not active and you have some kind of mixer UI, then it feels like a plugin from 1996 if you need to drag it to set it to the current position.

                      The proposed solution is correct: use a knob and then the drawRotaryKnob() function - even if your modwheel looks like a slider you want it to behave like a knob, so knob it is.

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

                      14

                      Online

                      2.0k

                      Users

                      12.8k

                      Topics

                      111.4k

                      Posts