00001 /* 00002 Copyright (C) 2010 Karol Krizka <kkrizka@gmail.com> 00003 00004 URL: http://www.krizka.net/projects/libmidi/ 00005 00006 This program is free software; you can redistribute it and/or modify 00007 it under the terms of the GNU General Public License as published by 00008 the Free Software Foundation; either version 3 of the License, or 00009 (at your option) any later version. 00010 00011 This program is distributed in the hope that it will be useful, 00012 but WITHOUT ANY WARRANTY; without even the implied warranty of 00013 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00014 GNU General Public License for more details. 00015 00016 You should have received a copy of the GNU General Public License 00017 along with this program; if not, write to the Free Software 00018 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 00019 00020 $Id$ 00021 */ 00022 00023 #ifndef MIDICHANNELEVENT_H_ 00024 #define MIDICHANNELEVENT_H_ 00025 00026 #include "Event.h" 00027 00028 namespace MIDI 00029 { 00031 00041 class ChannelEvent : public Event 00042 { 00043 public: 00045 ChannelEvent(); 00047 ChannelEvent(const ChannelEvent& o); 00049 ChannelEvent(dword timeDelta,byte command,int channel,int param1,int param2); 00050 00054 EventType type(); 00055 00062 byte command(); 00063 00067 int channel(); 00068 00072 int param1(); 00073 00077 int param2(); 00078 00083 virtual DataBuffer data(bool shorten=false); 00084 00085 virtual void debug(); 00086 00087 private: 00088 byte _command; 00089 int _channel; 00090 int _param1; 00091 int _param2; 00092 }; 00093 } 00094 00095 #endif // MIDICHANNELEVENT_H_