Oracle_label.hpp
Go to the documentation of this file.00001
00002
00003
00004
00005
00007
00008 #ifndef __ORACLE_LABEL_HPP__
00009 #define __ORACLE_LABEL_HPP__
00010
00011 #include <list>
00012 #include <iostream>
00013 using namespace std;
00014
00019
00020
00021 class O_label
00022 {
00023 protected:
00025 int statenb;
00027 int bufferef;
00029 int duration;
00031 int phrase;
00033 int section;
00034 public:
00036
00037
00038 O_label();
00040 O_label(int, int = 0, int = 0, int = 0, int = 0);
00042 O_label(const O_label & labelin);
00044 ~O_label(){};
00046
00048
00049
00050 int get_statenb();
00052 void set_statenb(int);
00054 int get_bufferef();
00056 void set_bufferef(int);
00058 int get_duration();
00060 void set_duration(int);
00062 int get_phrase();
00064 void set_phrase(int);
00066 int get_section();
00068 void set_section(int);
00070 };
00071
00073 class O_char : public O_label
00074 {
00075 protected:
00077 char letter;
00078
00079 public:
00081
00082
00083 O_char();
00085 O_char(char);
00087 O_char(const O_char &);
00089 ~O_char(){};
00091
00093
00094
00095 char get_letter();
00097
00099
00100
00101 bool operator== (const O_char &) const;
00103 friend ostream & operator<< (ostream &, const O_char &);
00105 };
00106
00108 class O_MIDI_mono : public O_label
00109 {
00110 protected:
00111 int pitch;
00112 int velocity;
00113 int channel;
00114
00115 public:
00117
00118
00119 O_MIDI_mono();
00121 O_MIDI_mono(int, int = 0, int = 0, int = 0, int = 0, int = 0, int = 0);
00123 O_MIDI_mono(const O_MIDI_mono &);
00125 ~O_MIDI_mono(){};
00127
00129
00130
00131 int get_pitch();
00133 void set_pitch(int);
00135 int get_velocity();
00137 void set_velocity(int);
00139
00141
00142
00143 bool operator== (const O_MIDI_mono &) const;
00145 friend ostream & operator<< (ostream &, const O_MIDI_mono &);
00147 };
00148
00150 class O_spectral : public O_label
00151 {
00152 protected:
00153 int pitch;
00154 float energy;
00155 list<float> coeffs;
00156
00157 public:
00159
00160
00161 O_spectral();
00163 O_spectral(int, list<float> &, int = 0, int = 0, int = 0, int = 0, int = 0);
00165 O_spectral(const O_spectral &);
00167 ~O_spectral(){};
00169
00171
00172
00173 int get_pitch();
00175 void set_pitch (int);
00177 float get_energy ();
00179 void set_energy (float);
00181 void set_energy(list<float> &);
00183 list<float> get_coeffs();
00186 void set_coeffs(list<float> &);
00188
00190
00191
00192 bool operator== (const O_spectral &) const;
00194 friend ostream & operator<< (ostream &, const O_spectral &);
00195 };
00198 #endif