hekeus@0: hekeus@0: hekeus@0: #include "ofMain.h" hekeus@0: #include "Voice.h" hekeus@0: hekeus@0: #include "ofxOsc.h" hekeus@0: hekeus@0: hekeus@0: hekeus@0: hekeus@0: hekeus@0: class melodyTriangle : public ofBaseApp{ hekeus@0: hekeus@0: public: hekeus@2: melodyTriangle(const char *host, int port, int numVoices, bool enableKeys, int voiceIdOffset); hekeus@0: hekeus@0: void setup(); hekeus@0: void update(); hekeus@0: void draw(); hekeus@0: hekeus@0: void keyPressed(int key); hekeus@0: void keyReleased(int key); hekeus@0: void mouseMoved(int x, int y ); hekeus@0: void mouseDragged(int x, int y, int button); hekeus@0: void mousePressed(int x, int y, int button); hekeus@0: void mouseReleased(int x, int y, int button); hekeus@0: void windowResized(int w, int h); hekeus@0: int numVoices; hekeus@2: int voiceIdOffset; hekeus@1: bool enableKeys; hekeus@0: float counter; hekeus@0: bool bSmooth; hekeus@0: //Voice *voices[NUMVOICES]; hekeus@0: Voice *voices[10]; hekeus@0: hekeus@0: int x1,y1,x2,y2,x3,y3;//Triangle Coords hekeus@0: int triangleHeight; hekeus@0: int voiceGrabbed; hekeus@0: void sendStatus(Voice v); hekeus@0: bool isInTriangle(int x, int y); hekeus@0: hekeus@0: hekeus@0: private: hekeus@0: ofxOscSender sender; hekeus@0: };