List of all members.
Public Types |
typedef math_types_ | math_types |
typedef math_types::vector3_type | vector3_type |
typedef math_types::matrix3x3_type | matrix3x3_type |
Public Member Functions |
vector3_type const & | n () const |
vector3_type & | n () |
real_type const & | w () const |
real_type & | w () |
size_t const | class_id () const |
| Plane () |
| Plane (vector3_type const &p1, vector3_type const &p2, vector3_type const &p3) |
| Plane (Plane const &p) |
| Plane (vector3_type const &n_val, real_type const &d_val) |
| Plane (vector3_type const &ndir, vector3_type const &p) |
bool | is_equal (plane_type const &p) const |
bool | isNearlyEqual (plane_type const &p) const |
void | set (plane_type const &p) |
void | set (vector3_type const &n_val, real_type const &d_val) |
void | set (vector3_type const &ndir, vector3_type const &p) |
void | set (vector3_type const &p1, vector3_type const &p2, vector3_type const &p3) |
void | set (real_type *c1, real_type *c2, real_type *c3) |
bool | is_coplanar (plane_type const &p) const |
void | compute_plane_vectors (vector3_type &tx, vector3_type &ty) const |
real_type | get_distance (vector3_type const &p) const |
real_type | signed_distance (vector3_type const &p) const |
void | compute_surface_points (std::vector< vector3_type > &) const |
vector3_type | get_support_point (vector3_type const &) const |
void | scale (real_type const &) |
void | rotate (matrix3x3_type const &R) |
void | translate (vector3_type const &T) |
void | flip () |
vector3_type | project (vector3_type const &point) const |
real_type | evaluate (vector3_type const &x) const |
vector3_type | gradient (vector3_type const &) const |
vector3_type | normal (vector3_type const &) const |
void | compute_collision_aabb (vector3_type const &, matrix3x3_type const &, vector3_type &min_coord, vector3_type &max_coord) const |
Public Attributes |
vector3_type | m_n |
| The Plane Normal.
|
real_type | m_d |
Protected Types |
typedef math_types::value_traits | value_traits |
typedef math_types::real_type | real_type |
typedef Plane< math_types > | plane_type |
Detailed Description
template<typename math_types_>
class OpenTissue::geometry::Plane< math_types_ >
A Plane. The Plane consist of all points x, where
n*x-d = 0
Member Typedef Documentation
template<typename math_types_>
template<typename math_types_>
template<typename math_types_>
template<typename math_types_>
template<typename math_types_>
template<typename math_types_>
Constructor & Destructor Documentation
template<typename math_types_>
Default constructor. Sets up a plane such that:
n = 0 and d =0
This means that all points no matter what their poisition would be lines in the plane.
template<typename math_types_>
Special constructor. Works in the same way as the corresponding assignment method.
- Parameters:
-
| p1 | A point in the plane. |
| p2 | A point in the plane. |
| p3 | A point in the plane. |
template<typename math_types_>
Copy constructor. Works in the same way as the corresponding assignment method.
- Parameters:
-
| Eq | Another plane equation. |
template<typename math_types_>
Special Constructor.
- Parameters:
-
| n | The direction of the normal vector of this plane. |
| d | The orthogonal distance from origo. |
template<typename math_types_>
Special constructor. Works in the same way as the corresponding assignment method.
- Parameters:
-
| ndir | The direction of the normal vector of this plane. |
| p | A point in the plane. |
Member Function Documentation
template<typename math_types_>
template<typename math_types_>
Compute Bounding Box. This method computes an axis aligned bounding box (AABB) that encloses the geometry.
- Parameters:
-
| r | The position of the model frame (i.e the coordinate frame the geometry lives in). |
| R | The orientation of the model frame (i.e the coordinate frame the geometry lives in). |
| min_coord | Upon return holds the minimum corner of the box. |
| max_coord | Upon return holds the maximum corner of the box. |
template<typename math_types_>
This method computes two orthogonal vectors, which span the plane.
These vectors are usefull when one wants to project points onto the plane.
- Parameters:
-
| tx | Upon return this vector holds the x-axe direction in the plane. |
| ty | Upon return this vector holds the y-axe direction in the plane. |
template<typename math_types_>
template<typename math_types_>
template<typename math_types_>
template<typename math_types_>
Retrieves the shortest distance from the specified point to this plane.
- Parameters:
-
- Returns:
- The shortest distance from the specified point to this plane.
template<typename math_types_>
template<typename math_types_>
template<typename math_types_>
Coplanar Test. This method test if the specified plane and this plane are coplanar. That is whatever their normals point in the same direction.
template<typename math_types_>
template<typename math_types_>
template<typename math_types_>
template<typename math_types_>
template<typename math_types_>
template<typename math_types_>
Project Point onto Plane.
- Parameters:
-
| point | The point that should be projected. |
- Returns:
- The projected point
template<typename math_types_>
Rotation of Plane. The transformation rule is easy to derive, let prime values denote the new value of this plane equation and non-prime the current values.
d = n*p n' = R*n d' = Rn*(t+Rp) | where p is old point in plane d' = (Rn)*t + (Rn)*(Rp) d' = n'*t + d
- Parameters:
-
| R | The rotation of the plane around origo. |
template<typename math_types_>
template<typename math_types_>
Assignment Method. Assigns the values of the specified plane equation to this plane equation.
- Parameters:
-
| Eq | Another plane equation. |
template<typename math_types_>
Assignment Method.
- Parameters:
-
| n | The direction of the normal vector of this plane. |
| d | The orthogonal distance from origo. |
template<typename math_types_>
Assignment Method. Assigns values to this plane in such a way that all the three specified points lie in the plane.
VERY IMPORTANT: The three points must all be different and not collinear.
- Parameters:
-
| p1 | A point in the plane. |
| p2 | A point in the plane. |
| p3 | A point in the plane. |
template<typename math_types_>
Assignment Method. Assigns values to this plane in such a way, that the plane will have a unit vector normal in the same direction as the first argument, and in such a way that the second argument lies in the plane represented by this plane equation.
- Parameters:
-
| ndir | The direction of the normal vector of this plane. |
| p | A point in the plane. |
template<typename math_types_>
This method computes the plane equation from three given points which lies in the plane.
- Parameters:
-
| c1 | First point of the plane. |
| c2 | Second point of the plane. |
| c3 | Third point of the plane. |
template<typename math_types_>
Retrieves the shortest distance with sign from the specified point to this plane.
If the point lies on the side of the plane where the normal is pointing the sign would be positive. This side of the plane is known as the frontside. If the point was on the backside the sign would have been negative. The final possibility is that the point lies in the plane. In this case the reutrn value is zero.
- Parameters:
-
- Returns:
- The shortest signed distance from the specified point to this plane.
template<typename math_types_>
template<typename math_types_>
template<typename math_types_>
Member Data Documentation
template<typename math_types_>
The offset of the plane (in the direction of the normal) from the origin of the coordinate frame.
template<typename math_types_>
The documentation for this class was generated from the following file:
- /home/hauberg/Dokumenter/Capture/humim-tracker-0.1/src/OpenTissue/OpenTissue/core/geometry/geometry_plane.h