MCPcopy Create free account
hub / github.com/bspaans/python-mingus / stop_Note

Method stop_Note

mingus/midi/sequencer.py:161–176  ·  view source on GitHub ↗

Stop a note on a channel. If Note.channel is set, it will take presedence over the channel argument given here.

(self, note, channel=1)

Source from the content-addressed store, hash-verified

159 return True
160
161 def stop_Note(self, note, channel=1):
162 """Stop a note on a channel.
163
164 If Note.channel is set, it will take presedence over the channel
165 argument given here.
166 """
167 if hasattr(note, "channel"):
168 channel = note.channel
169 self.stop_event(int(note) + 12, int(channel))
170 self.notify_listeners(
171 self.MSG_STOP_INT, {"channel": int(channel), "note": int(note) + 12}
172 )
173 self.notify_listeners(
174 self.MSG_STOP_NOTE, {"channel": int(channel), "note": note}
175 )
176 return True
177
178 def stop_everything(self):
179 """Stop all the notes on all channels."""

Callers 7

stop_everythingMethod · 0.95
stop_NoteContainerMethod · 0.95
stop_NoteFunction · 0.45
improviser.pyFile · 0.45
pygame-piano.pyFile · 0.45
test_playnoteMethod · 0.45

Calls 2

stop_eventMethod · 0.95
notify_listenersMethod · 0.95

Tested by 1

test_playnoteMethod · 0.36