HISE Logo Forum
    • Categories
    • Register
    • Login

    Get data from external script processor

    Scheduled Pinned Locked Moved General Questions
    19 Posts 4 Posters 722 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 @ulrik
      last edited by

      @ulrik said in Get data from external script processor:

      EDITED changed to a cleaner snippet using the Global Routing Manager

      Can you show me the original version without the routing manager, since that doesn't work in the fx plugin?

      I can see in your snippet that your UI script is undeferred, which definitely points to another solution because as soon as I defer it the script no longer functions and a UI script should always be deferred in my experience.

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

      Christoph HartC ulrikU 2 Replies Last reply Reply Quote 0
      • Christoph HartC
        Christoph Hart @d.healey
        last edited by

        @d-healey said in Get data from external script processor:

        a UI script should always be deferred in my experience.

        Not if you're ONLY doing actual realtime MIDI processing in your interface's callback. There is a legitimate use case for this but in most cases it isn't.

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

          @d-healey here's the old snippet, the TriggerBtn in the external script processor is connected to the TriggerBtn in the Main script

          I also made both the note on and note off messages delayed

          HiseSnippet 1850.3oc6YE0aaaCDVJIZn1sqXcnXXORXrGbFRckcbRrWQWSbhcWPZZxhy51PQw.sDsMQnI0jnSqQQ.F1ur89dY+T1+fsiTRVTtNcodsCnCUHA17ti7Nd7i28ojiCEdjnHQnkcwSmDPrrugS2Ib4vcGhobq82yx9SbNkDIQOGICoCFPBsZMI.GEQ7srsW9gJqrKrhk94OePKLCy8HYhrrdhf5QdDcDUlI83sOfxXcv9jSoiLrt9166I36JXhwPDsriqU.16L7.xiwJyVxw5avQCsr+Rm0I90Zz.uQ80W2qQyFda4gaP7p1aK2Z399q2f32yu9F0wV1eTaepTD1UhkjHK6UZI7mzcn347XG7DZDsGinFT0pK34XwcDLe0VTI0Z2gTl+woopHKXQON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8wiYxcBBH3PEAEPqBFpU1hAEkgk5DHEK.EtU1ro9oQC2sZ5tUUsUmJFLfQNT3SxsxpV6PqdNmvTghV12EQdBwC.cFwxTuAJ6vvxtxIrYVoiamdHLqb.7FJy7RsT4s49F9dyhWnvfSwPWKFCcyDLTqwRofqQO2vIqAzkghfm7nHqebVTDHIBNo1mebHAp3FeLSiNTnZUhCmjbQ4U4k.LhD9igrPdZRJxjIJf6143ln3evinxIljMeqwc5pFh2x4Xpza37iwklSLBU.dWDiILN+Xm186C.sr.bEmN+v6F5klt+ZWxaJbamSHXcqrHU0EP7am2VH3J+1B1K+tfr+JuWS1e5YxbI6WZImXNbYUDL3xALShKajiT6ZHfehhwQlLEiqxkLt6m0meViLKYXPxbVyBR2F66CVUZ5KfTZd1BE0GQ.Chs0j+88tDJZoz6CFGMr7KKcltSxkybQUJELPwY5BEwGiHvanhlne4WOKpE0e.ioqrC+.GJksKP+OG6jdeweIWKLGakr784hMy.gl+kpMfiy3qOzK7+E8BOQLVwF+PrLjpfOvE2tPOHORBaL0cD6kTn43wtoPltDtudveAOIJqlhwTJqlpzbKdy3s30c5BcT08b0avOSOF88.zD8PBzqUc.UM2wP9Ft+wa+Ftwb0OE3TGEHhxsvcIinmBWEiLEpX+FR9YMUaS46Bzdmqp+7AcfM4bmSWrbbnF5syHwXtLGT60RDn5+aHB7dPAkbbUJjFicoiBXj17yILnptNF+TmjWSKUZNr7xGJ3hfgBN0y7f9DR5eVZiXetancjR387xjb6sOgvHXSP6Wr8i.vFNT8VdKXtn5aLus4dd84NwgKRcAD89aifk+Pif+sMB9uvGivdghexKlFnBmdMsDXey0+iWJ3bnZLppklZn4Y4HnJ2O44keodkIVaQm35K5DqunSbiEchatnSbqEchM9mmnpIzNikhQwWMsrN731Zd011s4X.kquQX823BBYSB
          

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

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

            @ulrik said in Get data from external script processor:

            The delayed note off is taken from the external script processor (because it will be accurate)

            What do you mean by external script processor? Are you referring to the ReadNotes script?

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

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

              @d-healey said in Get data from external script processor:

              @ulrik said in Get data from external script processor:

              The delayed note off is taken from the external script processor (because it will be accurate)

              What do you mean by external script processor? Are you referring to the ReadNotes script?

              Yes

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

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

                So I can see a different route for this. Keep only GUI related stuff to the Interface script, any delaying of events can be done in another script processor, and updating the keyboard colours can be done with a timer (or multiple timers).

                If you add Synth.deferCallbacks(true); at the top of your UI script it will force you to separate GUI stuff from real-time MIDI stuff.

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

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

                  @d-healey said in Get data from external script processor:

                  So I can see a different route for this. Keep only GUI related stuff to the Interface script, any delaying of events can be done in another script processor, and updating the keyboard colours can be done with a timer (or multiple timers).

                  If you add Synth.deferCallbacks(true); at the top of your UI script it will force you to separate GUI stuff from real-time MIDI stuff.

                  Well that isn't the issue, the issue is that I can't get data from the "ReadNotes" script when I compile it as Midi FX plugin, it will not work

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

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

                    @ulrik said in Get data from external script processor:

                    I can't get data

                    What do you mean? If you're trying to pass information from the ReadNotes script to the UI script then I think you are doing it wrong :) The scripts should be able to function separately.

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

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

                      @d-healey My question was, how do I pass data from the "ReadNotes" script to the main script,
                      well that is indeed working but, it's not working if I export the project as Midi FX plugin.

                      Let me ask this instead:
                      Is it possible to get data from the ReadNotes" script to the main script, if I export the project as a Midi FX plugin?
                      The "ReadNotes" script is not meant to function separately, the script is there for the reason to pass data to the main script.

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

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

                        @ulrik said in Get data from external script processor:

                        Is it possible to get data from the ReadNotes" script to the main script, if I export the project as a Midi FX plugin?

                        Not sure, I haven't worked with MIDI FX. Are you relying on a global variable to pass this data back? If so that might be the cause of the issue.

                        @ulrik said in Get data from external script processor:

                        The "ReadNotes" script is not meant to function separately, the script is there for the reason to pass data to the main script.

                        I understand this is your design, but separating UI logic from realtime processing is usually the way to go. Unless there is some reason why that can't be done I would recommend exploring it, although of course it might require too much disruption to implement it in your current project.

                        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 @ulrik
                          last edited by

                          @ulrik Another try to get data
                          I have a sliderpack in the ReadNotes script, and in the main script
                          They are connected via sliderPackData, and it works in Hise.

                          externalslp.gif

                          but as soon as I compile and export to Midi FX plugin, the connection is broken.

                          @Christoph-Hart is it possible to make sub containers, with script processor to work in a Midi FX Plugin, is it not meant to work or is it a bug?
                          If it's not meant to work, is it possible to make changes to the Hise code so it will work?

                          this is the snippet

                          HiseSnippet 1990.3oc6Y8taabbD+NJcFgmSJZBLJ5mZ2RzOPUPvbjhRhzoFljRTNBxxlUTwI8CEoqtaH4Beb2K2sTVrAFHnuQ8MnOB8QIuAsyt2e3QJRaYV6hZCe.FR6ry+1Ylc1eiU+PgKDEIBMLsuXV.XX9oVClwk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ceANbbTfHZAEO.lvt.uqFkmnZL1P3GzyLmm9g37qqbqe9gGiGxUJy.pbZntza4wHMdMfwq8ACX72CZnrv7BES8wArIA9PO9UfO11W6iegUx+eKoTWrV9LAWDLVvYt4SzmC3cvQifv799JOPcjR0iCYTtW6yAeflun8229wXwFMou9FEKp8F+WvYk4qesUr6RTW.Iu+9PvVe7gf+aeH3+E1XB0MT78twyhnpS+DME7by0+UYKZclZMoV5zGyykSvtbeuq6hp5FBVeSEb2MUvFapf6soBt+lJ3AapfMe8BpdDpyToXR7USCiy52SC71zrGmhU45aDF+G.Jkbwq.
                          

                          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 Ok I investigated how to visually display the delayed note ons and note offs without actually reading them from an external script processor (since it's not possible to do that when compiling to a Midi FX plugin).
                            So I used the

                            Content.callAfterDelay()
                            

                            function applied to 16 separate panel components and got it to work, you can see the effect here, when I rotate the polygons (delaying the note on and offs), the keys will be painted according to the delay.

                            polygonarp.gif

                            Thank you David for pressing me to deal with the task in another way, finally it worked 🙏🏻

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

                            d.healeyD orangeO 2 Replies Last reply Reply Quote 4
                            • d.healeyD
                              d.healey @ulrik
                              last edited by

                              @ulrik Nice! You always make such cool GUIs!

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

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

                                @d-healey Thank you David!

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

                                1 Reply Last reply Reply Quote 0
                                • orangeO
                                  orange @ulrik
                                  last edited by

                                  @ulrik Interesting and inspiring GUI! Very cool.

                                  develop Branch / XCode 13.1
                                  macOS Monterey / M1 Max

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

                                    @orange Thank you!

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

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

                                    25

                                    Online

                                    1.7k

                                    Users

                                    11.8k

                                    Topics

                                    103.1k

                                    Posts