65 #ifndef PLUGINFUNCTIONS_VIEWCONTROL_HH
66 #define PLUGINFUNCTIONS_VIEWCONTROL_HH
71 #include <ACG/Scenegraph/DrawModes.hh>
72 #include <ACG/GL/GLState.hh>
79 const int ALL_VIEWERS = -2;
80 const int ACTIVE_VIEWER = -1;
82 const int VIEW_FREE = 0;
83 const int VIEW_TOP = 1;
84 const int VIEW_BOTTOM = 2;
85 const int VIEW_LEFT = 3;
86 const int VIEW_RIGHT = 4;
87 const int VIEW_FRONT = 5;
88 const int VIEW_BACK = 6;
292 int _viewer = ALL_VIEWERS);
303 void viewHome(
int _viewer = ALL_VIEWERS);
313 void viewAll(
int _viewer = ALL_VIEWERS);
370 double fovy(
int _viewer = ACTIVE_VIEWER);
421 void setFixedView(
int _mode,
int _viewer = ACTIVE_VIEWER );
448 void flyTo (
const ACG::Vec3d &_center,
bool _move_back =
true,
double _time=1000.0);
469 void viewerSnapshot(
int _viewer, QImage& _image,
int _width = 0,
int _height = 0,
470 bool _alpha =
false,
bool _hideCoordsys =
false,
int _samples = 1);
475 void invalidatePickCaches();
479 #endif //PLUGINFUNCTIONS_HH
void perspectiveProjection(int _viewer)
Switch to perspective Projection.
ACG::SceneGraph::DrawModes::DrawMode drawMode(int _viewer)
Get the current draw Mode of a Viewer.
Viewer::ViewerProperties & viewerProperties(int _id)
Get the viewer properties Use this functions to get basic viewer properties such as backgroundcolor o...
void translate(const ACG::Vec3d &_vector, int _viewer)
Translate viewer pos by given vector.
void setSceneRadius(double _radius, int _viewer)
Set the background color of the examiner widget.
void allowRotation(bool _mode, int _viewer)
const ACG::Vec3d sceneCenter(int _viewer)
Get the current scene center.
void viewingDirection(const ACG::Vec3d &_dir, const ACG::Vec3d &_up, int _viewer)
Set the viewing direction.
void setTrackBallCenter(const ACG::Vec3d &_center, int _viewer)
Set the trackball Center.
void setDrawMode(const ACG::SceneGraph::DrawModes::DrawMode &_mode, int _viewer)
Set the draw Mode of a Viewer. .
void rotate(const ACG::Vec3d &_axis, const double _angle, const ACG::Vec3d &_center, int _viewer)
Rotate Scene around axis.
void setScenePos(const ACG::Vec3d &_center, const double _radius, int _viewer)
Set the Scene position.
void setBackColor(OpenMesh::Vec4f _color)
Set the background color of the examiner widget.
void viewHome(int _viewer)
Go to home position.
const ACG::Vec3d trackBallCenter(int _viewer)
Get the trackball Center.
void lookAt(const ACG::Vec3d &_eye, const ACG::Vec3d &_center, const ACG::Vec3d &_up, int _viewer)
Set the look at transformation directly.
DLLEXPORT double fovy(int _viewer)
Get field of view angle.
ACG::Vec3d eyePos(int _viewer)
Get the current viewer position.
void viewerSnapshot(int _viewer, QImage &_image, int _width, int _height, bool _alpha, bool _hideCoordsys, int _samples)
Take a snapshot of a viewer.
double sceneRadius()
Returns the current scene radius from the active examiner widget.
void setFixedView(int _mode, int _viewer)
Set a fixed View for a viewer.
void setFOVY(double _fovy)
Set field of view angle.
void viewingRay(int _x, int _y, ACG::Vec3d &_outOrigin, ACG::Vec3d &_outDirection)
Retrieve a viewing ray from the active examiner that can be used for raycasting.
bool isProjectionOrthographic(int _viewer)
Check if the projection is orthographic.
void orthographicProjection(int _viewer)
Switch to orthographic Projection.
void flyTo(const ACG::Vec3d &_position, const ACG::Vec3d &_center, double _time)
Fly to point and viewing direction (animated).
void setMainGLContext()
Set current GL Context to main context.
ACG::Vec3d upVector(int _viewer)
Get the current up vector.
void viewAll(int _viewer)
View the whole scene.