Message.getEventId()



  • I don't remember if this is the way it should be but,
    Console.print the EventId in NoteOff Callback is 1 number below the EventId in NoteOn Callback, is this the way it should be? Has it always....?
    Maybe I miss something here when I log it
    look here:

    HiseSnippet 764.3ocsU01aSCCD1tqFQKLDShe.Q6SshRUJrMPLgXr9BJB5VEcLw2l7bbZsVpcThagJD+kQ7O.NmjtjLRQaUh7ob28b1O2km6xnPEiGEoBQ3ZmsLfivOjLdoTOs6TpPhb5gvOhLjFo4gVItNdY.MJh6hv3sduwAtVUT7yud6wTepjwybgPmqDL9GEyD5LuiN5CBe+ATW9YhY4Pu2QNLkrqxWMG3yVDaT.kcEcB+DpAVEBBeu9tBsJbrlp4Q.liUtKGOU8UYB9yEQhK84FiNnwvAk3F0cpv2czpZMBgvUGkU4akT4OgLT3Jt1eVG3wwArxxHeO.WoHkpVfRcVGkFn7cMGvZnGNG8plPucHiYgh.cVDC2d.wQBeb7nPaOOsRvhp7SLoqBPH0smQuhOHDLtNiFGXa2xZea6lG5MWxzBkzRIOQo4mJazr92qWyWwn9VRq2XMDtS3SQ6IbsAvIymcIOrQyC2ttE7jfaQQbmyA2B8xqQsJlXhTEx6u.XUCc3bdwSwwENlXQXapqaJa5zxR1xZQKK6UfgxJR4yaGDJfiY2DbNtud2m5317v5+nt0MqIOu7EU70jiswzwwMlr0Jd8Phv8ulNPJkpUFe77VGgLeTBU99lSvvoaD1LXTdjzDaHiudnkP8gF3JffZonb7d2N4HKQijCnR5HE5SC3o1YB1NkHXQohL3sO6zipoFMbpO.W.OTKLzA2iu.VHjnnqQ5witRqBfUB+kbGF5Tty8o5hShlUNoAf9QAIuQVKi.8V9UR2gwS6RGOKsZukzcGxHglMsb9VoD9Bcs+27McY21j9ddblNirUIC9xltY6NPkOolqExICo5Pw2PXBLFMF12y3.SjRtObQDbEihJw11Xa5Li4R2XieCOoA6XrwoA6rJHZFkEptfkLoXVmd+XO.mjw+IoF7KMv1pCJd5AxiX21FMC1xeAiYZEOC3d4477MHmWrA4r2Fjy9aPNGrA47xMHmW8Oyw7C12MWqlkLl.NF0OdMBF2WRAUVrhD8G.Z3ecD
    


  • Well the way you're doing it I would expect the result you are seeing.

    It works like this.

    You press a note, so the on note callback generates a note ID of 1

    You then play a note with Synth.addNoteOn which will have an ID of 2 (which is what you see in the Console the first time you load your snippet).

    Then you release the key, this is the release of the first event so it will also have an ID of 1. And this is what you're outputting to the console so it will always be one less than the note you created in on note.

    In other words you are outputting two different things in the two callbacks. In on note on you are outputting the ID of your new note that you create with Synth.addNoteOn, you are not outputting Message.getEventId(). In the note off callback though you are outputting the event ID that is triggered when you press/release a key, here you are outputting Message.getEventId().



  • @d-healey Ahh, of course, thank you! 👍


Log in to reply
 

9
Online

622
Users

2.5k
Topics

20.3k
Posts