Forum

    • Register
    • Login
    • Search
    • Categories

    Script missing LAF element

    General Questions
    3
    21
    149
    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.
    • MikeB
      MikeB last edited by

      Since this can't be changed via LAF, how can I script this?

      Bildschirmfoto 2021-05-30 um 10.26.57.png

      "One hour of trial and error can save 10 minutes of reading the manual."
      "It's easier to hit the developer with feature requests than to spend 10 minutes reading the manual. :-)))"
      HISE Develop - Mac Pro 5.1, OS X 10.14.6, Projucer 6.02, Xcode 10.3

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

        @MikeB Settings.getMidiInputDevices() and Settings.toggleMidiInput() are the functions you'll need.

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

        1 Reply Last reply Reply Quote 1
        • MikeB
          MikeB last edited by

          Sorry David - I know you mean well but:
          There is neither in the ApiCollection, nor in the complete forum, nor in the documentation
          an example for Settings.getMidiInputDevices() or Settings.toggleMidiInput()
          So what should I do with it?

          "One hour of trial and error can save 10 minutes of reading the manual."
          "It's easier to hit the developer with feature requests than to spend 10 minutes reading the manual. :-)))"
          HISE Develop - Mac Pro 5.1, OS X 10.14.6, Projucer 6.02, Xcode 10.3

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

            @MikeB Are you using the latest scriptnode version?

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

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

              @d-healey
              Version 2.1.0
              7 Mai 2021
              Build 650

              "One hour of trial and error can save 10 minutes of reading the manual."
              "It's easier to hit the developer with feature requests than to spend 10 minutes reading the manual. :-)))"
              HISE Develop - Mac Pro 5.1, OS X 10.14.6, Projucer 6.02, Xcode 10.3

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

                You need to update, I didn't add the MIDI devices stuff until about May 15th.

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

                1 Reply Last reply Reply Quote 0
                • MikeB
                  MikeB last edited by

                  Ok thanks I will update
                  But that doesn't explain the function either, does it?

                  "One hour of trial and error can save 10 minutes of reading the manual."
                  "It's easier to hit the developer with feature requests than to spend 10 minutes reading the manual. :-)))"
                  HISE Develop - Mac Pro 5.1, OS X 10.14.6, Projucer 6.02, Xcode 10.3

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

                    @MikeB Yep I added comments to all the functions

                    13ae2dfc-4185-49b0-8937-7e53fdf5faaa-image.png

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

                    1 Reply Last reply Reply Quote 1
                    • MikeB
                      MikeB last edited by

                      Thanks David - This looks good - now I just need a few examples how to use one or the other
                      and I'll program my own settings window 🙂

                      PS: a little patreon video maybe?

                      "One hour of trial and error can save 10 minutes of reading the manual."
                      "It's easier to hit the developer with feature requests than to spend 10 minutes reading the manual. :-)))"
                      HISE Develop - Mac Pro 5.1, OS X 10.14.6, Projucer 6.02, Xcode 10.3

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

                        @MikeB You only need those two functions + your GUI, probably radio buttons but you could do it with panels, combo boxes, or sliderpacks, whatever you prefer.

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

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

                          I just added LAF support for the MIDI channel list 🙂

                          I still need to test it and I'll make a pull request tomorrow.

                          0729a3fa-cd85-47f6-9879-984fd824606d-image.png

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

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

                            I've added a pull request to the Scriptnode branch for this now.

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

                            Lindon 1 Reply Last reply Reply Quote 2
                            • Lindon
                              Lindon @d.healey last edited by

                              @d-healey - could you do one for the midi device list too? Asking for a friend...

                              HISE Development for hire.
                              www.channelrobot.com

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

                                @Lindon That's already there 😉 it's a list of toggle buttons (as is the channel list). If you check the obj.parentType in the LAF togglebutton function you can filter out the Midi Sources buttons.

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

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

                                  @d-healey - oh yeah - obviously - how silly of me...once its in the scriptnode branh could you ddo a quick demo of what you do to make it work?

                                  HISE Development for hire.
                                  www.channelrobot.com

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

                                    @Lindon Midi sources is already in scriptnode, I didn't add it.

                                    const var laf = Engine.createGlobalScriptLookAndFeel();
                                    
                                    laf.registerFunction("drawToggleButton", function(g, obj)
                                    {
                                        if (obj.parentType == "MidiSources")
                                        {
                                            obj.value == 0 ? g.setColour(Colours.darkgrey) : g.setColour(Colours.white);
                                            g.drawAlignedText(obj.text, obj.area, "left");
                                        }    
                                    });
                                    

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

                                    1 Reply Last reply Reply Quote 0
                                    • MikeB
                                      MikeB last edited by MikeB

                                      @d-healey
                                      but the Midi-Channel List is in your scriptnode?
                                      On your page?

                                      "One hour of trial and error can save 10 minutes of reading the manual."
                                      "It's easier to hit the developer with feature requests than to spend 10 minutes reading the manual. :-)))"
                                      HISE Develop - Mac Pro 5.1, OS X 10.14.6, Projucer 6.02, Xcode 10.3

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

                                        It's in this branch - https://github.com/davidhealey/HISE/tree/channelListLAF - just waiting for @Christoph-Hart to merge it.

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

                                        1 Reply Last reply Reply Quote 0
                                        • MikeB
                                          MikeB last edited by

                                          Ok i can wait

                                          The question is rather where to merge it in
                                          I hope in "scriptnode" and not in
                                          "scriptnode_codegen_rewrite"
                                          or in both

                                          "One hour of trial and error can save 10 minutes of reading the manual."
                                          "It's easier to hit the developer with feature requests than to spend 10 minutes reading the manual. :-)))"
                                          HISE Develop - Mac Pro 5.1, OS X 10.14.6, Projucer 6.02, Xcode 10.3

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

                                            @MikeB I've made the pull request on the scriptnode branch.

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

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

                                            16
                                            Online

                                            1.1k
                                            Users

                                            7.0k
                                            Topics

                                            64.6k
                                            Posts