Public Types | Public Member Functions | Protected Attributes

OpenTissue::geometry::Tetrahedron< math_types_ > Class Template Reference

#include <geometry_tetrahedron.h>

Inheritance diagram for OpenTissue::geometry::Tetrahedron< math_types_ >:
OpenTissue::geometry::VolumeShape< math_types_ > OpenTissue::utility::ClassID< OpenTissue::geometry::Tetrahedron< math_types_ > > OpenTissue::geometry::BaseShape< math_types_ > OpenTissue::utility::ClassIDInterface OpenTissue::collision::GeometryInterface< math_types_ > OpenTissue::utility::ClassIDInterface

List of all members.

Public Types

typedef math_types_ math_types
typedef math_types::value_traits value_traits
typedef math_types::real_type real_type
typedef math_types::vector3_type vector3_type
typedef math_types::matrix3x3_type matrix3x3_type
typedef math_types::quaternion_type quaternion_type

Public Member Functions

size_t const class_id () const
 Tetrahedron ()
virtual ~Tetrahedron ()
 Tetrahedron (Tetrahedron const &tetrahedron_)
 Tetrahedron (vector3_type const &p0, vector3_type const &p1, vector3_type const &p2, vector3_type const &p3)
Tetrahedron const & operator= (Tetrahedron const &tetrahedron_)
void set (Tetrahedron const &t)
void set (vector3_type const &p0, vector3_type const &p1, vector3_type const &p2, vector3_type const &p3)
real_type area () const
void compute_surface_points (std::vector< vector3_type > &points) const
vector3_typep0 ()
vector3_typep1 ()
vector3_typep2 ()
vector3_typep3 ()
vector3_type const & p0 () const
vector3_type const & p1 () const
vector3_type const & p2 () const
vector3_type const & p3 () const
vector3_type center () const
void barycentric (vector3_type const &p, real_type &w1, real_type &w2, real_type &w3, real_type &w4) const
real_type diameter () const
vector3_type get_support_point (vector3_type const &v) const
void translate (vector3_type const &T)
void rotate (matrix3x3_type const &R)
void scale (real_type const &s)
real_type volume () const
void compute_collision_aabb (vector3_type const &r, matrix3x3_type const &R, vector3_type &min_coord, vector3_type &max_coord) const

Protected Attributes

vector3_type m_p0
 Tetrahedron vertex number 1.
vector3_type m_p1
 Tetrahedron vertex number 2.
vector3_type m_p2
 Tetrahedron vertex number 3.
vector3_type m_p3
 Tetrahedron vertex number 4.

template<typename math_types_>
class OpenTissue::geometry::Tetrahedron< math_types_ >


Member Typedef Documentation

template<typename math_types_>
typedef math_types_ OpenTissue::geometry::Tetrahedron< math_types_ >::math_types
template<typename math_types_>
typedef math_types::matrix3x3_type OpenTissue::geometry::Tetrahedron< math_types_ >::matrix3x3_type
template<typename math_types_>
typedef math_types::quaternion_type OpenTissue::geometry::Tetrahedron< math_types_ >::quaternion_type
template<typename math_types_>
typedef math_types::real_type OpenTissue::geometry::Tetrahedron< math_types_ >::real_type
template<typename math_types_>
typedef math_types::value_traits OpenTissue::geometry::Tetrahedron< math_types_ >::value_traits
template<typename math_types_>
typedef math_types::vector3_type OpenTissue::geometry::Tetrahedron< math_types_ >::vector3_type

Constructor & Destructor Documentation

template<typename math_types_>
OpenTissue::geometry::Tetrahedron< math_types_ >::Tetrahedron (  )  [inline]
template<typename math_types_>
virtual OpenTissue::geometry::Tetrahedron< math_types_ >::~Tetrahedron (  )  [inline, virtual]
template<typename math_types_>
OpenTissue::geometry::Tetrahedron< math_types_ >::Tetrahedron ( Tetrahedron< math_types_ > const &  tetrahedron_  )  [inline]
template<typename math_types_>
OpenTissue::geometry::Tetrahedron< math_types_ >::Tetrahedron ( vector3_type const &  p0,
vector3_type const &  p1,
vector3_type const &  p2,
vector3_type const &  p3 
) [inline]

Member Function Documentation

template<typename math_types_>
real_type OpenTissue::geometry::Tetrahedron< math_types_ >::area (  )  const [inline]
template<typename math_types_>
void OpenTissue::geometry::Tetrahedron< math_types_ >::barycentric ( vector3_type const &  p,
real_type w1,
real_type w2,
real_type w3,
real_type w4 
) const [inline]

Compute Barycentric Coordinates.

Parameters:
p The point for which the barycentric coordinates should be computed.
w1 Upon return this parameter contains the value of the first barycentric coordinate.
w2 Upon return this parameter contains the value of the second barycentric coordinate.
w3 Upon return this parameter contains the value of the third barycentric coordinate.
w4 Upon return this parameter contains the value of the fourth barycentric coordinate.
template<typename math_types_>
vector3_type OpenTissue::geometry::Tetrahedron< math_types_ >::center (  )  const [inline]
template<typename math_types_>
size_t const OpenTissue::geometry::Tetrahedron< math_types_ >::class_id (  )  const [inline, virtual]

Query the class ID.

Returns:
The object's class ID

Reimplemented from OpenTissue::utility::ClassID< OpenTissue::geometry::Tetrahedron< math_types_ > >.

template<typename math_types_>
void OpenTissue::geometry::Tetrahedron< math_types_ >::compute_collision_aabb ( vector3_type const &  r,
matrix3x3_type const &  R,
vector3_type min_coord,
vector3_type max_coord 
) const [inline]

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_>
void OpenTissue::geometry::Tetrahedron< math_types_ >::compute_surface_points ( std::vector< vector3_type > &  points  )  const [inline]
template<typename math_types_>
real_type OpenTissue::geometry::Tetrahedron< math_types_ >::diameter (  )  const [inline]
template<typename math_types_>
vector3_type OpenTissue::geometry::Tetrahedron< math_types_ >::get_support_point ( vector3_type const &  v  )  const [inline]
template<typename math_types_>
Tetrahedron const& OpenTissue::geometry::Tetrahedron< math_types_ >::operator= ( Tetrahedron< math_types_ > const &  tetrahedron_  )  [inline]
template<typename math_types_>
vector3_type const& OpenTissue::geometry::Tetrahedron< math_types_ >::p0 (  )  const [inline]
template<typename math_types_>
vector3_type& OpenTissue::geometry::Tetrahedron< math_types_ >::p0 (  )  [inline]
template<typename math_types_>
vector3_type& OpenTissue::geometry::Tetrahedron< math_types_ >::p1 (  )  [inline]
template<typename math_types_>
vector3_type const& OpenTissue::geometry::Tetrahedron< math_types_ >::p1 (  )  const [inline]
template<typename math_types_>
vector3_type& OpenTissue::geometry::Tetrahedron< math_types_ >::p2 (  )  [inline]
template<typename math_types_>
vector3_type const& OpenTissue::geometry::Tetrahedron< math_types_ >::p2 (  )  const [inline]
template<typename math_types_>
vector3_type& OpenTissue::geometry::Tetrahedron< math_types_ >::p3 (  )  [inline]
template<typename math_types_>
vector3_type const& OpenTissue::geometry::Tetrahedron< math_types_ >::p3 (  )  const [inline]
template<typename math_types_>
void OpenTissue::geometry::Tetrahedron< math_types_ >::rotate ( matrix3x3_type const &  R  )  [inline]
template<typename math_types_>
void OpenTissue::geometry::Tetrahedron< math_types_ >::scale ( real_type const &  s  )  [inline]
template<typename math_types_>
void OpenTissue::geometry::Tetrahedron< math_types_ >::set ( vector3_type const &  p0,
vector3_type const &  p1,
vector3_type const &  p2,
vector3_type const &  p3 
) [inline]
template<typename math_types_>
void OpenTissue::geometry::Tetrahedron< math_types_ >::set ( Tetrahedron< math_types_ > const &  t  )  [inline]
template<typename math_types_>
void OpenTissue::geometry::Tetrahedron< math_types_ >::translate ( vector3_type const &  T  )  [inline]
template<typename math_types_>
real_type OpenTissue::geometry::Tetrahedron< math_types_ >::volume (  )  const [inline]

Member Data Documentation

template<typename math_types_>
vector3_type OpenTissue::geometry::Tetrahedron< math_types_ >::m_p0 [protected]

Tetrahedron vertex number 1.

template<typename math_types_>
vector3_type OpenTissue::geometry::Tetrahedron< math_types_ >::m_p1 [protected]

Tetrahedron vertex number 2.

template<typename math_types_>
vector3_type OpenTissue::geometry::Tetrahedron< math_types_ >::m_p2 [protected]

Tetrahedron vertex number 3.

template<typename math_types_>
vector3_type OpenTissue::geometry::Tetrahedron< math_types_ >::m_p3 [protected]

Tetrahedron vertex number 4.


The documentation for this class was generated from the following file: