All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Public Member Functions | Private Attributes
fcl::KDOP< N > Class Template Reference

KDOP class describes the KDOP collision structures. K is set as the template parameter, which should be 16, 18, or 24 The KDOP structure is defined by some pairs of parallel planes defined by some axes. For K = 16, the planes are 6 AABB planes and 10 diagonal planes that cut off some space of the edges: (-1,0,0) and (1,0,0) -> indices 0 and 8 (0,-1,0) and (0,1,0) -> indices 1 and 9 (0,0,-1) and (0,0,1) -> indices 2 and 10 (-1,-1,0) and (1,1,0) -> indices 3 and 11 (-1,0,-1) and (1,0,1) -> indices 4 and 12 (0,-1,-1) and (0,1,1) -> indices 5 and 13 (-1,1,0) and (1,-1,0) -> indices 6 and 14 (-1,0,1) and (1,0,-1) -> indices 7 and 15 For K = 18, the planes are 6 AABB planes and 12 diagonal planes that cut off some space of the edges: (-1,0,0) and (1,0,0) -> indices 0 and 9 (0,-1,0) and (0,1,0) -> indices 1 and 10 (0,0,-1) and (0,0,1) -> indices 2 and 11 (-1,-1,0) and (1,1,0) -> indices 3 and 12 (-1,0,-1) and (1,0,1) -> indices 4 and 13 (0,-1,-1) and (0,1,1) -> indices 5 and 14 (-1,1,0) and (1,-1,0) -> indices 6 and 15 (-1,0,1) and (1,0,-1) -> indices 7 and 16 (0,-1,1) and (0,1,-1) -> indices 8 and 17 For K = 18, the planes are 6 AABB planes and 18 diagonal planes that cut off some space of the edges: (-1,0,0) and (1,0,0) -> indices 0 and 12 (0,-1,0) and (0,1,0) -> indices 1 and 13 (0,0,-1) and (0,0,1) -> indices 2 and 14 (-1,-1,0) and (1,1,0) -> indices 3 and 15 (-1,0,-1) and (1,0,1) -> indices 4 and 16 (0,-1,-1) and (0,1,1) -> indices 5 and 17 (-1,1,0) and (1,-1,0) -> indices 6 and 18 (-1,0,1) and (1,0,-1) -> indices 7 and 19 (0,-1,1) and (0,1,-1) -> indices 8 and 20 (-1, -1, 1) and (1, 1, -1) --> indices 9 and 21 (-1, 1, -1) and (1, -1, 1) --> indices 10 and 22 (1, -1, -1) and (-1, 1, 1) --> indices 11 and 23. More...

#include <kDOP.h>

List of all members.

Public Member Functions

Vec3f center () const
 The (AABB) center.
FCL_REAL depth () const
 The (AABB) depth.
FCL_REAL dist (std::size_t i) const
FCL_REALdist (std::size_t i)
FCL_REAL distance (const KDOP< N > &other, Vec3f *P=NULL, Vec3f *Q=NULL) const
 The distance between two KDOP<N>. Not implemented.
FCL_REAL height () const
 The (AABB) height.
bool inside (const Vec3f &p) const
 KDOP ()
 Creating kDOP containing nothing.
 KDOP (const Vec3f &v)
 Creating kDOP containing only one point.
 KDOP (const Vec3f &a, const Vec3f &b)
 Creating kDOP containing two points.
KDOP< N > operator+ (const KDOP< N > &other) const
 Create a KDOP by mergin two KDOPs.
KDOP< N > & operator+= (const Vec3f &p)
 Merge the point and the KDOP.
KDOP< N > & operator+= (const KDOP< N > &other)
 Merge two KDOPs.
bool overlap (const KDOP< N > &other) const
 Check whether two KDOPs are overlapped.
FCL_REAL size () const
 Size of the kDOP (used in BV_Splitter to order two kDOPs)
FCL_REAL volume () const
 The (AABB) volume.
FCL_REAL width () const
 The (AABB) width.

Private Attributes

FCL_REAL dist_ [N]
 Origin's distances to N KDOP planes.

Detailed Description

template<size_t N>
class fcl::KDOP< N >

KDOP class describes the KDOP collision structures. K is set as the template parameter, which should be 16, 18, or 24 The KDOP structure is defined by some pairs of parallel planes defined by some axes. For K = 16, the planes are 6 AABB planes and 10 diagonal planes that cut off some space of the edges: (-1,0,0) and (1,0,0) -> indices 0 and 8 (0,-1,0) and (0,1,0) -> indices 1 and 9 (0,0,-1) and (0,0,1) -> indices 2 and 10 (-1,-1,0) and (1,1,0) -> indices 3 and 11 (-1,0,-1) and (1,0,1) -> indices 4 and 12 (0,-1,-1) and (0,1,1) -> indices 5 and 13 (-1,1,0) and (1,-1,0) -> indices 6 and 14 (-1,0,1) and (1,0,-1) -> indices 7 and 15 For K = 18, the planes are 6 AABB planes and 12 diagonal planes that cut off some space of the edges: (-1,0,0) and (1,0,0) -> indices 0 and 9 (0,-1,0) and (0,1,0) -> indices 1 and 10 (0,0,-1) and (0,0,1) -> indices 2 and 11 (-1,-1,0) and (1,1,0) -> indices 3 and 12 (-1,0,-1) and (1,0,1) -> indices 4 and 13 (0,-1,-1) and (0,1,1) -> indices 5 and 14 (-1,1,0) and (1,-1,0) -> indices 6 and 15 (-1,0,1) and (1,0,-1) -> indices 7 and 16 (0,-1,1) and (0,1,-1) -> indices 8 and 17 For K = 18, the planes are 6 AABB planes and 18 diagonal planes that cut off some space of the edges: (-1,0,0) and (1,0,0) -> indices 0 and 12 (0,-1,0) and (0,1,0) -> indices 1 and 13 (0,0,-1) and (0,0,1) -> indices 2 and 14 (-1,-1,0) and (1,1,0) -> indices 3 and 15 (-1,0,-1) and (1,0,1) -> indices 4 and 16 (0,-1,-1) and (0,1,1) -> indices 5 and 17 (-1,1,0) and (1,-1,0) -> indices 6 and 18 (-1,0,1) and (1,0,-1) -> indices 7 and 19 (0,-1,1) and (0,1,-1) -> indices 8 and 20 (-1, -1, 1) and (1, 1, -1) --> indices 9 and 21 (-1, 1, -1) and (1, -1, 1) --> indices 10 and 22 (1, -1, -1) and (-1, 1, 1) --> indices 11 and 23.

Definition at line 82 of file kDOP.h.


Constructor & Destructor Documentation

template<size_t N>
fcl::KDOP< N >::KDOP ( )

Creating kDOP containing nothing.

Definition at line 109 of file kDOP.cpp.

template<size_t N>
fcl::KDOP< N >::KDOP ( const Vec3f v)

Creating kDOP containing only one point.

Definition at line 120 of file kDOP.cpp.

template<size_t N>
fcl::KDOP< N >::KDOP ( const Vec3f a,
const Vec3f b 
)

Creating kDOP containing two points.

Definition at line 136 of file kDOP.cpp.


Member Function Documentation

template<size_t N>
Vec3f fcl::KDOP< N >::center ( ) const [inline]

The (AABB) center.

Definition at line 141 of file kDOP.h.

template<size_t N>
FCL_REAL fcl::KDOP< N >::depth ( ) const [inline]

The (AABB) depth.

Definition at line 123 of file kDOP.h.

template<size_t N>
FCL_REAL fcl::KDOP< N >::dist ( std::size_t  i) const [inline]

Definition at line 154 of file kDOP.h.

template<size_t N>
FCL_REAL& fcl::KDOP< N >::dist ( std::size_t  i) [inline]

Definition at line 159 of file kDOP.h.

template<size_t N>
FCL_REAL fcl::KDOP< N >::distance ( const KDOP< N > &  other,
Vec3f P = NULL,
Vec3f Q = NULL 
) const

The distance between two KDOP<N>. Not implemented.

Definition at line 222 of file kDOP.cpp.

template<size_t N>
FCL_REAL fcl::KDOP< N >::height ( ) const [inline]

The (AABB) height.

Definition at line 117 of file kDOP.h.

template<size_t N>
bool fcl::KDOP< N >::inside ( const Vec3f p) const

Definition at line 165 of file kDOP.cpp.

template<size_t N>
KDOP< N > fcl::KDOP< N >::operator+ ( const KDOP< N > &  other) const

Create a KDOP by mergin two KDOPs.

Definition at line 214 of file kDOP.cpp.

template<size_t N>
KDOP< N > & fcl::KDOP< N >::operator+= ( const Vec3f p)

Merge the point and the KDOP.

Definition at line 185 of file kDOP.cpp.

template<size_t N>
KDOP< N > & fcl::KDOP< N >::operator+= ( const KDOP< N > &  other)

Merge two KDOPs.

Definition at line 203 of file kDOP.cpp.

template<size_t N>
bool fcl::KDOP< N >::overlap ( const KDOP< N > &  other) const

Check whether two KDOPs are overlapped.

Definition at line 153 of file kDOP.cpp.

template<size_t N>
FCL_REAL fcl::KDOP< N >::size ( ) const [inline]

Size of the kDOP (used in BV_Splitter to order two kDOPs)

Definition at line 135 of file kDOP.h.

template<size_t N>
FCL_REAL fcl::KDOP< N >::volume ( ) const [inline]

The (AABB) volume.

Definition at line 129 of file kDOP.h.

template<size_t N>
FCL_REAL fcl::KDOP< N >::width ( ) const [inline]

The (AABB) width.

Definition at line 111 of file kDOP.h.


Member Data Documentation

template<size_t N>
FCL_REAL fcl::KDOP< N >::dist_[N] [private]

Origin's distances to N KDOP planes.

Definition at line 151 of file kDOP.h.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines


fcl
Author(s): Jia Pan
autogenerated on Tue Jan 15 2013 16:05:31