Class: AudioToolbox::MIDIProgramChangeMessage

Inherits:
MIDIChannelMessage show all
Defined in:
lib/music_player.rb,
ext/music_player/music_player.c

Instance Method Summary collapse

Methods inherited from MIDIChannelMessage

#==, #add, #channel, #data1, #data2, #status

Constructor Details

#initialize(opts) ⇒ MIDIProgramChangeMessage

Returns a new instance of MIDIProgramChangeMessage.



169
170
171
172
173
# File 'lib/music_player.rb', line 169

def initialize(opts)
  channel, program = required_opts(opts, :channel, :program)
  super(:status => mask | channel,
        :data1  => program)
end

Instance Method Details

#maskObject



167
# File 'lib/music_player.rb', line 167

def mask; 0xC0 end