HISE Logo Forum
    • Categories
    • Register
    • Login

    Issues with playing a midi file via midi player and onNoteOff not being called

    Scheduled Pinned Locked Moved Scripting
    4 Posts 3 Posters 99 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.
    • T
      thrice801
      last edited by

      Hi,

      I'm trying to make a midi effect type plugin where I play a midi drum loop based on a single keypress. It's kind of working, however, I can't figure out how to properly do it where it doesn't cause issues in abelton (I am using the vst instrument workaround for abelton). Note on is working the way I want it to, but the note off events aren't being written, so it shows up as a giant messed up blob of midi when you try to record the output.

      The following, the clip labeled track 1 is me dragging one of the clips in manually. What you see after is the issue I'm trying to solve (I can confirm there are no note offs being sent from the midi player by logging also).
      Screen Shot 2025-04-21 at 4.20.49 PM.png

      Here is what my chain looks like. And for context, in the onNoteOn/off in the main interface I am doing Message.ignoreEvent(true); (to stop the main key being pressed from propogating and dual triggering), but even if I say Message.ignoreEvent(false) in the note off, none of the loops note off messages are being sent, only note on. Anyone know how I could fix this properly? (also just to be clear, in Script Processor 1 onNoteOn/off, I am doing Message.sendToMidiOut(), but onNoteOff callback never fires)

      Screen Shot 2025-04-21 at 4.41.53 PM.png

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

        @thrice801 I think you need to have the ScriptProcessor that has

        Message.sendToMidiOut()
        

        in both NoteOn and NoteOff callback, to be 1 level below the MIDI Player.

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

        VirtualVirginV T 2 Replies Last reply Reply Quote 1
        • VirtualVirginV
          VirtualVirgin @ulrik
          last edited by VirtualVirgin

          @ulrik said in Issues with playing a midi file via midi player and onNoteOff not being called:

          @thrice801 I think you need to have the ScriptProcessor that has

          Message.sendToMidiOut()
          

          in both NoteOn and NoteOff callback, to be 1 level below the MIDI Player.

          ulrik is right and hopefully this will solve your problem.

          Message.sendToMidiOut()
          

          needs to be in a MIDI processor script after any scripts that generate your MIDI.
          I always use a container which just contains the Message.sendToMidiOut() for all MIDI callbacks (onNoteOn(), onNoteOff(), onController()) at the lowest point in the module tree.

          1 Reply Last reply Reply Quote 0
          • T
            thrice801 @ulrik
            last edited by

            @ulrik that did it thanks! swore I tried it yesterday but think I did something wrong

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

            47

            Online

            1.7k

            Users

            11.7k

            Topics

            102.3k

            Posts