Menu

#7 midi_player send notes off

1.0
closed
2016-08-23
2016-07-07
No

send note offs for all sounding notes when you stop (for logic to avoid stuck notes) -- there should be an array of size 128 for each channel found in the midi file. Add 1 to the array element when note-on is issued, subtract 1 when note-off is issued. When the player is stopped, send note-offs for any non-zero entries. A linear scan is OK here because stopping is not time-critical or frequent.

Discussion

  • Shuqi Dai

    Shuqi Dai - 2016-08-23
    • status: open --> closed
    • assigned_to: Shuqi Dai
     
  • Shuqi Dai

    Shuqi Dai - 2016-08-23

    Commit [r527]
    [Solution]
    channel_notes_count[16][128], an array of size 128 for each channel found in the midi file.
    Add 1 to the array element when note-on is issued, subtract 1 when note-off is issued.
    When the player is stopped, send note-offs for any non-zero entries.
    send notes off to each playing note individually according to the notes counting.
    [Modification] in midi_player.srp

     

    Related

    Commit: [r527]


Log in to post a comment.

MongoDB Logo MongoDB