23 #include <tulip/Coord.h>
24 #include <tulip/Matrix.h>
25 #include <tulip/BoundingBox.h>
26 #include <tulip/Observable.h>
58 Coord eyes=Coord(0,0,10), Coord up=Coord(0,-1,0),
59 double zoomFactor=0.5,
double sceneRadius=10);
102 void move(
float speed);
106 void strafeLeftRight(
float speed);
110 void strafeUpDown(
float speed);
114 void rotate(
float angle,
float x,
float y,
float z);
126 Vector<int, 4> getViewport()
const;
140 void setZoomFactor(
double zoomFactor);
155 void setEyes(
const Coord& eyes);
170 void setCenter(
const Coord& center);
185 void setUp(
const Coord& up);
199 Coord screenTo3DWorld(
const Coord &point)
const;
205 Coord worldTo2DScreen(
const Coord &obj)
const;
210 virtual void getXML(std::string &outString);
215 virtual void setWithXML(
const std::string &inString,
unsigned int ¤tPosition);
222 void getModelviewMatrix(Matrix<float, 4> &modelviewMatrix)
const {
223 modelviewMatrix=this->modelviewMatrix;
229 void getProjectionMatrix(Matrix<float, 4> &projectionMatrix)
const {
230 projectionMatrix=this->projectionMatrix;
236 void getTransformMatrix(Matrix<float, 4> &transformMatrix)
const {
237 transformMatrix=this->transformMatrix;
243 void getProjAndMVMatrix(
const Vector<int, 4>& viewport,Matrix<float, 4> &projectionMatrix,Matrix<float, 4> &modelviewMatrix)
const;
248 void getTransformMatrix(
const Vector<int, 4>& viewport,Matrix<float, 4> &transformMatrix)
const;
263 void initProjection(
const Vector<int, 4>& viewport,
bool reset=
true);
268 void initProjection(
bool reset=
true);
273 void initModelView();
278 void setSceneRadius(
double sceneRadius,
const BoundingBox sceneBoundingBox=BoundingBox());
286 Coord center,eyes,up;
289 BoundingBox sceneBoundingBox;
293 Matrix<float, 4> modelviewMatrix;
294 Matrix<float, 4> projectionMatrix;
295 Matrix<float, 4> transformMatrix;