HISE Logo Forum
    • Categories
    • Register
    • Login

    [ScriptNode] Add < > == to control.logic_op

    Scheduled Pinned Locked Moved Solved Feature Requests
    9 Posts 3 Posters 587 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.
    • A
      aaronventure
      last edited by

      Feels like low-hanging fruit, really.

      • Greater Than
      • Greater Equal
      • Lesser Than
      • Lesser Equal
      • Equal

      Integration should be easy, too, just increasing the parameter max and assigning these to values 3-7.

      A 1 Reply Last reply Reply Quote 0
      • A
        aaronventure @aaronventure
        last edited by

        @aaronventure Also a range node, that will have three parameters:

        • value
        • min
        • max

        and will output the value limited to min/max, just like the Math.range() method. This could also be done using the aforementioned expansion to logic_op using < and > but it's much simpler as it's a single node.

        C 1 Reply Last reply Reply Quote 0
        • C
          Consint @aaronventure
          last edited by

          @aaronventure This already exists: https://docs.hise.audio/scriptnode/list/control/minmax.html

          A 1 Reply Last reply Reply Quote 0
          • A
            aaronventure @Consint
            last edited by

            @Consint it doesn't take an unscaled value. Min max takes 0-1 and spreads it over the range, taking into account skew for the curve.

            You cannot be putting in a filter frequency unscaled and dynamically adjust the clamping down to 5k like you can with Math.range.

            Yes,you can just use the expr node and Math.range but then the min and max aren't dynamic.

            C 1 Reply Last reply Reply Quote 0
            • C
              Consint @aaronventure
              last edited by

              @aaronventure said in [ScriptNode] Add < > == to control.logic_op:

              You cannot be putting in a filter frequency unscaled and dynamically adjust the clamping down to 5k like you can with Math.range.

              Maybe I'm not thinking about something, but I would say you can do exactly that:

              HiseSnippet 1309.3ocwX0raiTDDtGa2Nq8tf1E3AvRKGxJEEYm8Oj3PbhSLXAIwrSHZuE5LS63VdltGloch8BHgDbXuw48FuFbK2YQBQdB3H2VdBfplYrmwYbRbrxlMQJxc0U00WWU8UU6z1WYwCBT9DiR6NziSLtC0bnT2sQWlPRZsAw38oawBzb+JQhVenGKHfaSLLx+Yn.iREHg+7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16EoOtZ0pjKx0+5qd0usZFWS93YKCbRoe7uBccQJtWxsdDrtjaMT4kw0uY0qVxGbMne1b+0jqAYmqqKSgNVLebTaV2mh9lhzLAA9CncDNHMY4w6O2TXraoCevn2H0L5fS9H1zQZyGLps8lvjGaXfZnAiZkeCQbqOphMcWiIOp5+R8Yl7V+gO7zyVCexqe88mwtH2+e+yPvjm9UjLEDWRUzJmjsJZk5W0B3vuz1aqB3o35u4C23z33uoqRo6BOQXB+W+uewOu5M.ApH95V96DtaI5lRF7HJ6KJmGM1NEVh.cGnnkb82COioomAe9ijG+3fIFHOZlHYckpmKK7UYy22g5l3MjtLKe09wOmAup2JTBPJkg+iFvQav5J0HGc1RAWgsXeKqIOpLFtx7Z3CmWCez7Z3imWCex7Z3SmWC+jK2P7+SSbmbrrEnts2LZliwHBHLpi7+om18+B
              
              A 1 Reply Last reply Reply Quote 0
              • A
                aaronventure @Consint
                last edited by

                @Consint your output is permanently set to the max, what.gif

                because the scaler is working on the raw value output, which it expects to be 0-1.

                you can see that if i change the parameter range to 0-1, it responds properly, but if you're working with a skewed range, you have to do conversion and iterating is a mess.

                No matter the range, the value knob will (like any parameter that isn't unscaled) take a 0-1 state of the input paramter, regardless of the input parameter's range. But you can see that the frequencies don't match; this would only work with linear input.

                C 1 Reply Last reply Reply Quote 1
                • C
                  Consint @aaronventure
                  last edited by

                  @aaronventure Now I understand the problem. Thanks for the explanation.

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

                    What about a cable version of this node:

                    Link Preview Image
                    HISE | Docs

                    favicon

                    (docs.hise.dev)

                    It would cover more use cases for unscaled range modifications and the clipping functionality could be achieved by setting the input and output range to the same value.

                    A 1 Reply Last reply Reply Quote 0
                    • A
                      aaronventure @Christoph Hart
                      last edited by aaronventure

                      @Christoph-Hart I mean why not, although that requires management of the input min and max values, so you can't easily plug any input toggle in there.

                      Why not both? You'd just have to make the unscaled version of minmax 😄

                      I don't think there's such thing as enough nodes

                      1 Reply Last reply Reply Quote 0
                      • A aaronventure referenced this topic on
                      • A aaronventure marked this topic as a question on
                      • A aaronventure has marked this topic as solved on
                      • First post
                        Last post

                      32

                      Online

                      1.7k

                      Users

                      11.8k

                      Topics

                      103.0k

                      Posts