[PD] How to add/remove MIDI notes from a list using MIDI in and note on/off?

JC Pedroza nemesis4go10 at hotmail.com
Wed Nov 12 03:20:19 CET 2014


I understand what poly does, what I don't understand is how it helps to solve this problem.

Sorry for any confusion.

----------------------------------------
> Date: Wed, 12 Nov 2014 02:15:54 +0100
> From: colet.patrice at free.fr
> To: nemesis4go10 at hotmail.com; pd-list at iem.at
> Subject: Re: [PD] How to add/remove MIDI notes from a list using MIDI in and note on/off?
>
> I don't understand why not doing this:
>
> [notein]
> | |
> [poly]
>
> It seems to be the same thing.
>
> from [poly] help file:
>
> "The [poly] object takes a stream of pitch/velocity pairs and outputs
> triples containing voice number, pitch and velocity.
> You can pack the output and use the route object to route messages
> among a bank of voices depending on the first outlet.
> [poly] can be configured to do voice stealing or not (the default.)"
>
>
> Le 12/11/2014 00:13, JC Pedroza a écrit :
>> Right now I'm handling MIDI note on/off like this:<br><br><div id="inlineImage0" style="display: inline-block"><script type="jsv#1086_"></script> <span contenteditable="true"> </span> <div style="display: inline-block" unselectable="on" contenteditable="false" class="inlineImage" initheight="257" initwidth="377"><img src="cid:inlineImage0" height="257" width="377"></div> <span contenteditable="true"> </span><script type="jsv/1086_"></script></div><br>(also including this file as attachment)<div><br></div><div>The idea for now is that left outlet (note on) adds the MIDI note to the list, and right outlet (note off) deletes that note from the list. <span style="font-size: 12pt;">That's where I'm stuck at the moment. </span><span style="font-size: 12pt;"> Can [poly] help me implement that logic? </span></div><div><br></div><div>I'm using [list-extend] to add the notes to a list, but I can't figure out how to remove the note from the list once the key is released (note off). I think I need to use a combination of [list-find] and [list-delete], but I can't make make it work.</div><div><br></div><div><br></div><div>----------------------------------------<br>> Date: Tue, 11 Nov 2014 23:23:22 +0100<br>> From: colet.patrice at free.fr<br>> To: pd-list at lists.iem.at<br>> Subject: Re: [PD] How to add/remove MIDI notes from a list using MIDI in and note on/off?<br>><br>> hi,<br>> what about using [poly] instead?<br>><br>><br>> Le 11/11/2014 13:53, JC Pedroza a écrit :<br>> > I need to populate a list with the MIDI notes that are being pressed, and remove the note from the list when the key is released.<br>> ><br>> > One idea is to use [notein], and if the velocity is> 0 then add the note to the list, and if the velocity == 0 then remove the note from the list. But I have no idea of how to implement this.<br>> ><br>> > I think I need [list-extend], [list-find], and [list-delete], but I just can't figure out an implementation.<br>> ><br>> > How can I do this?<br>> > _______________________________________________<br>> > Pd-list at lists.iem.at mailing list<br>> > UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list<br>><br>><br>> _______________________________________________<br>> Pd-list at lists.iem.at mailing list<br>> UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list<br></div>
>
>
 		 	   		  


More information about the Pd-list mailing list