-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCoordSystemNode.cpp
More file actions
38 lines (29 loc) · 1.16 KB
/
CoordSystemNode.cpp
File metadata and controls
38 lines (29 loc) · 1.16 KB
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
#include "CoordSystemNode.h"
#include <Math/Vector.h>
#include <Math/Matrix.h>
#include <Geometry/Line.h>
#include <Meta/OpenGL.h>
#include <Logging/Logger.h>
using namespace OpenEngine::Math;
CoordSystemNode::CoordSystemNode() {
}
void CoordSystemNode::Apply(Renderers::RenderingEventArg arg, Scene::ISceneNodeVisitor& v) {
// draw coordinate system axis
arg.renderer.
DrawLine( Geometry::Line(Math::Vector<3,float>(0.0),
Math::Vector<3,float>(1000.0,0.0,0.0) ),
Math::Vector<3,float>(1.0,0.0,0.0) );
arg.renderer.
DrawLine( Geometry::Line(Math::Vector<3,float>(0.0),
Math::Vector<3,float>(0.0,1000.0,0.0) ),
Math::Vector<3,float>(0.0,1.0,0.0) );
arg.renderer.
DrawLine( Geometry::Line(Math::Vector<3,float>(0.0),
Math::Vector<3,float>(0.0,0.0,1000.0) ),
Math::Vector<3,float>(0.0,0.0,1.0) );
/* Vector<3,float> v(1,1,0);
Vector<3,float> c(0,0,0);
Vector<3,float> color(0.5, 0.5, 0);
view->GetRenderer()->DrawLine( Geometry::Line(c,v), color);
*/
}