All Classes Namespaces Files Functions Variables Typedefs Friends Macros Pages
Public Member Functions | List of all members
ignition::math::Plane< T > Class Template Reference

A plane and related functions. More...

#include <ignition/math/Plane.hh>

Public Member Functions

 Plane ()
 Constructor. More...
 
 Plane (const Vector3< T > &_normal, T _offset=0.0)
 Constructor from a normal and a distanec. More...
 
 Plane (const Vector3< T > &_normal, const Vector2< T > &_size, T _offset)
 Constructor. More...
 
virtual ~Plane ()
 Destructor. More...
 
Distance (const Vector3< T > &_origin, const Vector3< T > &_dir) const
 Get distance to the plane give an origin and direction. More...
 
const Vector3< T > & Normal () const
 Get the plane offset. More...
 
Vector3< T > & Normal ()
 Get the plane offset. More...
 
Offset () const
 Get the plane offset. More...
 
Plane< T > & operator= (const Plane< T > &_p)
 Equal operator. More...
 
void Set (const Vector3< T > &_normal, const Vector2< T > &_size, T _offset)
 Set the plane. More...
 
const Vector2< T > & Size () const
 Get the plane size. More...
 
Vector2< T > & Size ()
 Get the plane size. More...
 

Detailed Description

template<typename T>
class ignition::math::Plane< T >

A plane and related functions.

Constructor & Destructor Documentation

template<typename T>
ignition::math::Plane< T >::Plane ( )
inline

Constructor.

template<typename T>
ignition::math::Plane< T >::Plane ( const Vector3< T > &  _normal,
_offset = 0.0 
)
inline

Constructor from a normal and a distanec.

Parameters
[in]_normalThe plane normal
[in]_offsetOffset along the normal
template<typename T>
ignition::math::Plane< T >::Plane ( const Vector3< T > &  _normal,
const Vector2< T > &  _size,
_offset 
)
inline

Constructor.

Parameters
[in]_normalThe plane normal
[in]_sizeSize of the plane
[in]_offsetOffset along the normal

References ignition::math::Plane< T >::Set().

template<typename T>
virtual ignition::math::Plane< T >::~Plane ( )
inlinevirtual

Destructor.

Member Function Documentation

template<typename T>
T ignition::math::Plane< T >::Distance ( const Vector3< T > &  _origin,
const Vector3< T > &  _dir 
) const
inline

Get distance to the plane give an origin and direction.

Parameters
[in]_originthe origin
[in]_dira direction
Returns
the shortest distance

References ignition::math::Vector3< T >::Dot().

template<typename T>
const Vector3<T>& ignition::math::Plane< T >::Normal ( ) const
inline

Get the plane offset.

template<typename T>
Vector3<T>& ignition::math::Plane< T >::Normal ( )
inline

Get the plane offset.

template<typename T>
T ignition::math::Plane< T >::Offset ( ) const
inline

Get the plane offset.

template<typename T>
Plane<T>& ignition::math::Plane< T >::operator= ( const Plane< T > &  _p)
inline

Equal operator.

Parameters
_panother plane
Returns
itself
template<typename T>
void ignition::math::Plane< T >::Set ( const Vector3< T > &  _normal,
const Vector2< T > &  _size,
_offset 
)
inline

Set the plane.

Parameters
[in]_normalThe plane normal
[in]_sizeSize of the plane
[in]_offsetOffset along the normal

Referenced by ignition::math::Plane< T >::Plane().

template<typename T>
const Vector2<T>& ignition::math::Plane< T >::Size ( ) const
inline

Get the plane size.

template<typename T>
Vector2<T>& ignition::math::Plane< T >::Size ( )
inline

Get the plane size.


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