summaryrefslogtreecommitdiff
path: root/src/obtsDevice.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/obtsDevice.h')
-rw-r--r--src/obtsDevice.h48
1 files changed, 48 insertions, 0 deletions
diff --git a/src/obtsDevice.h b/src/obtsDevice.h
new file mode 100644
index 0000000..884600b
--- /dev/null
+++ b/src/obtsDevice.h
@@ -0,0 +1,48 @@
+#ifndef OBTSDEVICE_H
+#define OBTSDEVICE_H
+
+#include "ofMain.h"
+
+/*
+created with icon, colour, linesize etc
+in order to draw need to know:
+
+time now: in order to draw relatively (this is not actual time as it can draw historically)
+scale: fixed (defined at object creation)
+or always zoom out? (begin time defined at object creation)
+
+events: connect(is create) disconnect() call(* obtsDevice) hangup() sms(* obtsDevice)
+functions: draw(time) getPosition(time)
+
+variables: pointer to icon image
+
+*/
+
+struct timeseg{
+ timeseg(float _st,float _et){
+ startTime=_st;
+ endTime=_et;
+ }
+ float startTime;
+ float endTime;
+};
+
+
+class obtsDevice
+{
+ public:
+ obtsDevice();
+ obtsDevice(string &imsi,ofImage *_icon,ofVec2f _coords);
+ virtual ~obtsDevice();
+ void draw(float timeScale); //units per second
+ void connect();
+ void disconnect();
+ protected:
+ private:
+ string IMSI;
+ ofVec2f coords; //angular coords
+ vector<timeseg> connectionHistory;
+ ofImage *icon;
+};
+
+#endif // OBTSDEVICE_H