diff options
Diffstat (limited to 'liveengine/src/testApp.h')
| -rwxr-xr-x | liveengine/src/testApp.h | 243 |
1 files changed, 243 insertions, 0 deletions
diff --git a/liveengine/src/testApp.h b/liveengine/src/testApp.h new file mode 100755 index 0000000..fa04e0b --- /dev/null +++ b/liveengine/src/testApp.h @@ -0,0 +1,243 @@ +#pragma once + +//#include <GL/glxew.h> + +#include "ofMain.h" +#include "ofxXmlSettings.h" + +/* +modprobe snd-virmidi +have had problems with it not being recognised - rebuild seemed to fix it + + +6 controllers +each note switches in 6 new visuals which are at the same strengths +as the previous bunch + +is it necessary to represent them seperately? + +maybe take them all in, but initially modulate one picture on the strength of the strongest + +maybe each object is a plugin and the 6 controllers affect 6 parameters of it +ie speed, matting type, colour tweak + +object that plays when a note is received can be called a track, a sample, a bank, a layer? + +object remembers playback head/ heads + +initial footage set for each track: program change? +(does this leave any room for creative input) or set via gui? + +video playback object +still image object + +load files in gui - loadable area + +creative input - alter layers live via AVS compatible system which also allows local MIDI control, +scripting, manipulating layers etc + +probably pretty tricky to create a .ape loader - difficulty in recreating the windows GUI + +probably a lot easier to think about a way of making a modular editor that can be manipulated live +nice to think about making scripted layers - using nseel or other + +initially - divide screen into grid - play notes with fade + +class that loads an svg and maps controllers to layers +layers are there but maybe its best to draw all of the colours mapped in some way rather than cutting out layers - colour transformation based on a hue angle + + +fix feedback - direction etc +all drawn/ scaled from middle +colours for svgs +multi screen +loader/ programme changer - seperate xml for main programme and for each content section +script engine for scaling +more specific colour filtering for photos +auto masks based on colour + +wrap around/ scale textures + +3d blocks +non random colours + +option to randomise colours on each note + +--make transparent + +--interface for exploring and saving - swapping? + + +*/ + + + +#define OF_ADDON_USING_OFXMIDIIN + + +#include "ofxMidi.h" +#include "ofxFensterManager.h" + +#include "ofxGui.h" + + +#include "viewport.h" +#include "threadNI.h" + + +/* +enum PropertyAttribute { + None = 0, + ReadOnly = 1 << 0, + DontEnum = 1 << 1, + DontDelete = 1 << 2 +}; +*/ + +class previewWindow; +class guiWindow; +class kinectWindow; + +//#define GRAB_TEXTURE + +class testApp : public ofxFensterListener, public ofxMidiListener{ + + public: + + void setup(); + void update(); + void draw(); + + void keyPressed(int key, ofxFenster* win); + void keyPressed(int key); + void keyReleased(int key); + void mouseMoved(int x, int y ); + void mouseDragged(int x, int y, int button); + void mousePressed(int x, int y, int button); + void mouseReleased(int x, int y, int button); + void windowResized(int w, int h); + void gotMessage(ofMessage msg); + void dragEvent(ofDragInfo dragInfo); + void dragEvent(ofDragInfo dragInfo,ofxFenster* win); + + void saveSettings(string filename); + + void mousePressedEvent(ofMouseEventArgs &args); + void keyPressedEvent(ofKeyEventArgs &args); + void windowEvent(ofResizeEventArgs &args); + + void nmidiMessage(int event,int data1, int data2); + + void makeColours(); + + void toggleFPS(); + bool showFPS; + + ofxXmlSettings XML; + + unsigned char* controllers; + int note, mode; + + //to be moved into svg object gui + + bool debug; + + bool fullscreenoutput; + + float lastnoteTime; + + int fadetime; + int rotate; + float scale,fscale; + + int xshift,yshift; + + ofColor* controller_colours; + + float colShift; + + viewport vp1,vp2; + vector<viewport*> viewports; + int activeView; + + previewWindow *prevWin; + guiWindow *guiWin; + kinectWindow *kinectWin; + + ofxFenster* win; + + int midiChannel; + + ofxMidiIn midiIn; + + void newMidiMessage(ofxMidiEventArgs& eventArgs); + + playlist list; + + + ofxPanel gui; + ofxToggle reversemain; + ofxToggle controlColours; + ofxToggle noteRandomiseColours; + ofxToggle transparentBlack; + ofxButton resetDrawscale; + ofxButton resetFBscale; + ofxIntSlider fS; + ofxParameter<int> fadeScale; + ofxFloatSlider dT; + ofxParameter<float> decayTime; + ofxToggle oscScale; + ofxToggle breakOsc; + ofxToggle randomOsc; + ofxFloatSlider sA; + ofxParameter<float> scaleAmplitude; + ofxFloatSlider sF; + ofxParameter<float> scaleFrequency; + ofxToggle drawCloud; + ofxToggle drawSkel; + + float randOffs; + + void resetDrawscalePressed(bool & pressed); + void resetFBscalePressed(bool & pressed); + + + //kinect stuff + + bool useKinect; + + threadNI NIinstance; + +}; + +class kinectWindow: public ofxFensterListener{ +public: + ~kinectWindow(); + testApp *parent; + void setup(); + void setParent(testApp *p); + void draw(); +}; + + +class previewWindow: public ofxFensterListener{ +public: + ~previewWindow(); + ofFbo *rb; + void setup(); + void setBuffer(ofFbo *buffer); + void draw(); +}; + +class guiWindow: public ofxFensterListener{ +public: + ~guiWindow(); + testApp *parent; + void setup(); + void setParent(testApp *p); + void draw(); + void dragEvent(ofDragInfo dragInfo,ofxFenster* win); + void windowMoved(int x, int y); +}; + + |
