-
Notifications
You must be signed in to change notification settings - Fork 1
/
ofxIndustrialRobotVisualizer.h
executable file
·72 lines (56 loc) · 1.58 KB
/
ofxIndustrialRobotVisualizer.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
#ifndef _INDUSTRIAL_ROBOT_VISUALIZER
#define _INDUSTRIAL_ROBOT_VISUALIZER
#include "ofMain.h"
#include "ofConstants.h"
#include "ofxVectorMath.h"
#include "ofx3DUtils.h"
#include "ofxIndustrialRobotArmHelper.h"
#include "ofxIndustrialRobotController.h"
#include "ofxIndustrialRobotTimeline.h"
#include "ofxMSAInteractiveObject.h"
#include "ofx3DModelLoader.h"
class View : public ofxMSAInteractiveObject {
public:
View(){
//enableMouseEvents();
//enableKeyEvents();
click = false;
release = false;
}
bool click;
bool release;
virtual void onPress(int x, int y, int button) {
click = true;
release = false;
}
virtual void onRelease(int x, int y, int button) {
click = false;
release = true;
}
};
class ofxIndustrialRobotVisualizer {
public:
ofxIndustrialRobotVisualizer(ofxIndustrialRobotArmHelper * _helper, ofxIndustrialRobotController * _controller, ofBaseApp * _app, ofxIndustrialRobotTimeline * _timeline, ofxIndustrialRobotPlotter * _plotter);
void drawGeneric();
void draw3d(int x, int y, int w, int h);
void drawtop(int x, int y, int w, int h);
void drawside(int x, int y, int w, int h);
void drawGraphs(int x, int y, int w, int h);
void drawArm(int i, int w, int h);
void drawArm0();
void drawArm1();
void drawArm2();
void drawArm3();
void drawArm4();
View topView, sideView;
ofxIndustrialRobotArmHelper * helper;
ofxIndustrialRobotController * controller;
ofxIndustrialRobotTimeline * timeline;
ofxIndustrialRobotPlotter * plotter;
ofBaseApp * app;
float rotationSpeed;
ofxCamera camera;
ofxLight light1;
ofx3DModelLoader model;
};
#endif