diff options
Diffstat (limited to 'vfg/src/music.h')
| -rwxr-xr-x | vfg/src/music.h | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/vfg/src/music.h b/vfg/src/music.h index aa38f46..39ffd95 100755 --- a/vfg/src/music.h +++ b/vfg/src/music.h @@ -12,6 +12,8 @@ class note { int velocity;
int duration; //may be needed another time?
int updown; //-1 0 1 used for 3-button interaction
+ bool activated;
+ void playerActivated() { activated=true; }
};
//---------------------------------------------------------------------------------------------------------------------------------------------
class score {
@@ -34,11 +36,21 @@ class musicscore: public score { void parseMidi(string filename);
void setTimeframe(int millis);
void draw();
+
+ void playerControl(int key);
+ //in wrong object?
+ int missedTime;
private:
map<int,note*> notes; map<int,note*> stars;
int timeframe;
ofImage flake;
+
+ //in wrong object?
+ int interactionThresh;
+
+
+ int playerKey;
};
//---------------------------------------------------------------------------------------------------------------------------------------------
class song {
@@ -50,6 +62,7 @@ class song { void setTimeframe(int millis);
void draw();
bool isPlaying;
+ void playerControl(int key);
private:
ofSoundPlayer backing;
ofSoundPlayer melody;
@@ -57,6 +70,9 @@ class song { musicscore notes;
long startTime;
bool isPreroll;
+
+ int missedInterval;
+
};
//---------------------------------------------------------------------------------------------------------------------------------------------
|
