diff options
Diffstat (limited to 'liveengine/src/viewport.h')
| -rwxr-xr-x | liveengine/src/viewport.h | 69 |
1 files changed, 69 insertions, 0 deletions
diff --git a/liveengine/src/viewport.h b/liveengine/src/viewport.h new file mode 100755 index 0000000..c401c17 --- /dev/null +++ b/liveengine/src/viewport.h @@ -0,0 +1,69 @@ +#ifndef VIEWPORT_H
+#define VIEWPORT_H
+
+#include "ofxOpenNI.h"
+#include "ofMain.h"
+#include "playlist.h"
+
+#define NUM_NOTES 64
+#define START_NOTE 36
+#define NUM_CONTROLLERS 26
+#define START_CONTROLLER 102
+
+#define NOTHING 0
+#define BLOCKS 1
+#define LIST 2
+#define SOLID 3
+
+void bindTexture(ofBaseHasTexture &t);
+void unbindTexture(ofBaseHasTexture &t);
+void bindTex(ofTexture &tex);
+void unbindTex(ofTexture &tex); +
+#include "keyVar.h"
+
+class viewport
+{
+ public:
+ viewport();
+ viewport(int _w,int _h,int _x,int _y,float _r,int _ox,int _oy);
+ void setup(int _w,int _h,int _x,int _y,float _r,int _ox,int _oy);
+ void draw(float a,unsigned char* controllers,int xshift,int yshift,playlist &list,bool transparentBlack,int note,int mode,ofColor* controller_colours,bool controlColours,float scale,float fscale,float colShift);
+ void mapdraw(float a,unsigned char* controllers,int xshift,int yshift,playlist &list,bool transparentBlack,int note,int mode,ofColor* controller_colours,bool controlColours,float scale,float fscale,float colShift,bool drawCloud,bool drawSkel);
+ void setcam(map<string,string>&settings); + double getSetting(const string& setting); +
+ ofImage testtexture;
+ virtual ~viewport();
+ void setUG(ofxUserGenerator *_rUser);
+ ofFbo rb1,rb2,rb3;
+ float r;
+ bool isMapped; + + void setDefaults(); + void keyPressed(int key); + void keyReleased(int key); +
+ protected:
+ int x, y,w,h,ox,oy;
+ ofxUserGenerator *rUser;
+ private:
+ keyVar* vars; + + ofCamera camera; + ofNode target;
+
+};
+
+class mappedviewport: public viewport {
+ public: +
+ mappedviewport(int _w,int _h,int _x,int _y,float _r,int _ox,int _oy);
+ void setUG(ofxUserGenerator *_rUser);
+ void mapdraw(float a,unsigned char* controllers,int xshift,int yshift,playlist &list,bool transparentBlack,int note,int mode,ofColor* controller_colours,bool controlColours,float scale,float fscale,float colShift);
+ ofxUserGenerator *rUser; + private: +
+};
+
+#endif // VIEWPORT_H
|
