Open
Description
Just curious, but why is send
forcing a channel
on a message (here) even if the message had its channel field set explicitly? Isn't the main point of the message having a "channel" field in being able to prepare a set of messages assigned to different channels and have the MIDI interpreter send them to those channels, exactly as given?
Sure, I could always make sure to write midi.send(message, message.channel)
, but this now seems to defeat the purpose of the send
method's channel argument (and the MIDI
object out_channel
field) in being able to configure an out_channel
as some sort of a default when necessary.
A more meaningful design, IMO, could be:
- Whenever a parameter is passed to
send
, use it. - Otherwise, use
MIDIMessage.channel
, unless it is None. - ... in which case fall back to
MIDI.out_channel
.
Metadata
Metadata
Assignees
Labels
No labels