summaryrefslogtreecommitdiff
path: root/menuApp/src/dirscanner.h
diff options
context:
space:
mode:
Diffstat (limited to 'menuApp/src/dirscanner.h')
-rw-r--r--menuApp/src/dirscanner.h26
1 files changed, 20 insertions, 6 deletions
diff --git a/menuApp/src/dirscanner.h b/menuApp/src/dirscanner.h
index 1e70ed8..4512842 100644
--- a/menuApp/src/dirscanner.h
+++ b/menuApp/src/dirscanner.h
@@ -16,15 +16,22 @@ class timeSlot {
class playItem {
public:
+ playItem(){
+ loaded=0;
+ isFinished=false;
+ }
playItem(std::string _n){
filename=_n;
+ playItem();
}
string filename;
ofImage image;
ofVideoPlayer video;
+ int loaded; //0- none, 1- image, 2- mov
+ bool load(string filename);
void play();
void draw();
- bool isFinished();
+ bool isFinished;
float startTime;
};
@@ -34,7 +41,7 @@ class dirScanner {
dirScanner(std::string _d=""){
rootdir=_d;
}
- int getSlotForTime(int time);
+ int getSlotForTime();
string rootdir;
void scan();
vector<timeSlot> slots;
@@ -42,11 +49,18 @@ class dirScanner {
class dirPlayer {
public:
- dirPlayer(std::string _d){
- playdir=_d;
+ dirPlayer(){
+ currentslot=-1;
+ }
+ dirPlayer(dirScanner *_s){
+ scanner=_s;
+ dirPlayer();
}
vector<playItem> items;
string playdir;
- void load();
- void draw();
+ int currentslot;
+ dirScanner *scanner;
+ void load(std::string path);
+ bool draw();
+ int currentItem;
}; \ No newline at end of file