49 #ifndef OPENMESH_VDPROGMESH_VIEWINGPARAMETERS_HH
50 #define OPENMESH_VDPROGMESH_VIEWINGPARAMETERS_HH
55 #include <OpenMesh/Core/Geometry/VectorT.hh>
56 #include <OpenMesh/Core/Geometry/Plane3d.hh>
75 double modelview_matrix_[16];
78 float tolerance_square_;
91 void increase_tolerance() { tolerance_square_ *= 5.0f; }
92 void decrease_tolerance() { tolerance_square_ /= 5.0f; }
94 float fovy()
const {
return fovy_; }
95 float aspect()
const {
return aspect_; }
96 float tolerance_square()
const {
return tolerance_square_; }
98 void set_fovy(
float _fovy) { fovy_ = _fovy; }
99 void set_aspect(
float _aspect) { aspect_ = _aspect; }
100 void set_tolerance_square(
float _tolerance_square) { tolerance_square_ = _tolerance_square; }
102 const Vec3f& eye_pos()
const {
return eye_pos_; }
103 const Vec3f& right_dir()
const {
return right_dir_; }
104 const Vec3f& up_dir()
const {
return up_dir_; }
105 const Vec3f& view_dir()
const {
return view_dir_; }
106 Vec3f& eye_pos() {
return eye_pos_; }
107 Vec3f& right_dir() {
return right_dir_; }
108 Vec3f& up_dir() {
return up_dir_; }
109 Vec3f& view_dir() {
return view_dir_; }
111 void frustum_planes(
Plane3d _plane[4] )
113 for (
unsigned int i=0; i<4; ++i)
114 _plane[i] = frustum_plane_[i];
117 void get_modelview_matrix(
double _modelview_matrix[16])
119 for (
unsigned int i=0; i<16; ++i)
120 _modelview_matrix[i] = modelview_matrix_[i];
123 void set_modelview_matrix(
const double _modelview_matrix[16])
125 for (
unsigned int i=0; i<16; ++i)
126 modelview_matrix_[i] = _modelview_matrix[i];
129 void update_viewing_configurations();
139 #endif // OPENMESH_VDPROGMESH_VIEWINGPARAMETERS_HH defined
Definition: ViewingParameters.hh:72
ax + by + cz + d = 0
Definition: Plane3d.hh:74
Contains all the mesh ingredients like the polygonal mesh, the triangle mesh, different mesh kernels ...
Definition: MeshItems.hh:56