HISE Logo Forum
    • Categories
    • Register
    • Login

    NoteOffByEventID always firing....

    Scheduled Pinned Locked Moved General Questions
    15 Posts 2 Posters 519 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.
    • LindonL
      Lindon
      last edited by

      hmm, can anyone see what i'm doing wrong here?

      HiseSnippet 1801.3oc6Y8tbSaDDWJIBRDDFnkoS+P+v0LcXrKDGaS3OEJES9GiGHfm3zT9FyEoyw2D46TkNkDCCyviReT3QnOB8Qf2f18NIYcxQ1XBA5L.NyjXs2t686182d2dJsB3NjvPdfg4ba22mXXddq18Yhtq1ESYFMWSJPPBE6RbqVslwJ88wggDWCSyoenTCy4lwP84s2eErGl4PxDYXrCm5PdLsGUjIsUiGQ871.6R1l1SS6kazzgyVk6wi.zLsUUCery938HOAKUaJKCyyrtKUvCZKv.jLLmYEta+1c4Gxh0eGZHcWOh7gZFsAGEKdCtmqDwRoFq1k541JcUGZXXZ0JKFLcbL3xVaRcoCjmEKtnZ.TlE5wCyoFG7poCupSL7LzP2LwnC.A2MxCKxiLY5HY.JmkCYMYBBKjJ5qmt9eEtWxpEU3zsX7NUA3ERTerwaRxedq06zg3Hx.6LVa7rOsY5YGYs3pbl.dhDbpTK5Ow0hlS+0ZuuV68kPs2Ehgx4rZCkYp5OEP9N0yn+.e.A8PBT.JCpiqH7uO8KBepi.l9sCvrPedXNG2lzitMmIiHYB+8PxFAj+bKYVVW9pbbPgC816uArHKzl1XQTfht7fd7HlHG8X5INm7dr4vLer1bX5IixT.jLOdI1krZ6DP8EYiHwy2lHMCQ4oJwiZLUkYsPxszILQkd38gPO7frDLnC1gTZ4pUuFpd0pku671n4sA5Pn.c.N.sUDCcuAVtGQrJumOj9YhRK.isfzfLs2r4ZMoL+HwHsYfFCY4S3BxSh5sKIXjlloRA1FyXGqswpLjs6P73NvlPizxTET1szRYV1F2y2CNdDrTU7prSlHUOUZgz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CVUsqYW2951KaeC6aZeK6aa+K10.g0rMNsvUBMWCW2QGWOKEWVY35RVKVeY6EqU2FfRc65KOgfYtIodQCH2RCHuAGCjzGediPAwuM8E4pugiqb8Hs3gptH0eUytjN3Hu3lGzqF+PQ9fJ0Lr8W6mOwVLP0PWo2nuzLJ0XTKCiwEn+j8NpNct07boXrMUdgp0YxSlAIRL9MvNWpzUpz72YdSNi62kynN5glsHh.5d6QBzwdgKnGHDPmsYRtbisHpl0yD8SMdLbENb.DmHmvXQs262fPg4qu2JFtHYqBnOOd2hS+k46VbKdj.ZGcSLPTk6oBGIzFtJhCAPBCJhkswYNkrgq3mqJeN9c5wbUO7uvmjAqIe1LYvZoC9YybzC6DvetSbqRx5kYURfXKS8eAbNqMkOipk1hjkU0JUMj2W44NNxT5hPNnXapeBr45m.aV9DXyMNA1bySfM25DXysGqMx265ChD7dwk6ffVqqZU0zbcFFpVTUVF+GrPaCeC
      

      I am getting "Script Processor1:! onNoteOn() - Line 15, column 39: NoteOn with ID0 wasn't found"

      for every note I play - even though droneID is always zero.....

      HISE Development for hire.
      www.channelrobot.com

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

        I always reset my ids to -1 because I think 0 could be a valid event ID (I could be wrong though). I also always put a check before turning off notes.

        if (id != -1) Synth.noteOffByEventId(id);
        

        Edit: I just looked at your snippet and saw that you do have a safe check. hmm... I will do further tests.

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

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

          With that snippet I get a different error to you.

          onNoteOn() - Line 15, column 39: Hell breaks loose if you kill real events artificially!

          And it works fine if I run the drone once to populate the droneID.

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

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

            @d-healey actually its getting worse, if you turn OFF MIDI Input and toggle the Run button it will start to play a note, whihc is correct, you can play any other note and its fine - but play the SAME note (which should have a completely different ID) and it turns off the drone note...

            I cant seem to get my head around this MIDI model...

            HISE Development for hire.
            www.channelrobot.com

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

              Hehe I see the problem. I've made this mistake before too. You have a semicolon at the end of your if ()

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

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

                @d-healey oh yeah....thanks... lets see if that fixes problem I started with... thanks mate..

                HISE Development for hire.
                www.channelrobot.com

                LindonL 1 Reply Last reply Reply Quote 1
                • LindonL
                  Lindon @Lindon
                  last edited by

                  @Lindon yep that fixes that problem - now how to fix this turning off my drone note when I dont want it off...

                  HISE Development for hire.
                  www.channelrobot.com

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

                    @Lindon I shall investigate

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

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

                      The only time drone ID is set is when you start the drone. You need to update it in on note.

                      Actually ignore that.... more investigating

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

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

                        @d-healey
                        ok so adding this:

                        function onNoteOff()
                        {
                          Console.print("an OFF event");
                          Console.print("droneID is:" + droneID);  
                          Console.print("this event ID is:" + Message.getEventId());
                        };
                        

                        tells me the droneID and the eventID turning it off are different:

                        
                        Script Processor1: droneID is:139
                        Script Processor1: this event ID is:151
                        

                        HISE Development for hire.
                        www.channelrobot.com

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

                          I think I've figured it out.

                          If you turn off the run button and replace everything in your on note callback with Message.setNoteNumber(60); Then play a note, and then hold down a second note. When you release the second note the first note is cut-off too. This implies that there is some internal thingy that says you may only have one voice per note with the sine wave generator.

                          You'd need your script to retrigger your drone in note off if the user presses/releases the drone key.

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

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

                            @d-healey riiiiight.... wow thats very bad I think from a scripting notes basis..... Its not just the sine wave generator - I just replaced my sampler with the SWG so I could post the snippet....

                            HISE Development for hire.
                            www.channelrobot.com

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

                              With a sampler you should be able to choose what happens with the retrigger settings.

                              e8ab1563-bdcf-4f90-ac4f-a06f78da64a7-image.png

                              I just tested it with a sampler and it worked as expected. The voice count went up to 5 which is how many keys I was holding down and they were all triggering note 60.

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

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

                                @d-healey ahhh! OK I'll give it a try...

                                HISE Development for hire.
                                www.channelrobot.com

                                LindonL 1 Reply Last reply Reply Quote 0
                                • LindonL
                                  Lindon @Lindon
                                  last edited by

                                  @Lindon OK well that sorta fixed it I think. Which is a bit of a relief as a whole truck load of CR and AudioReward instruments use "granular like" multiples-of-the-same-note-playing techniques...

                                  HISE Development for hire.
                                  www.channelrobot.com

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

                                  28

                                  Online

                                  1.7k

                                  Users

                                  11.9k

                                  Topics

                                  103.6k

                                  Posts