TalanSoft Toolkits  201707
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Groups Pages
Public Member Functions | List of all members
cEllipsoid< T > Class Template Reference

Detailed Description

template<typename T>
class ni::cEllipsoid< T >

Ellipsoid template class.

Public Member Functions

 cEllipsoid (const sVec3< T > &aPos, const sVec3< T > &aRadius)
 
 cEllipsoid (const sVec3< T > &aRadius=sVec3< T >::One())
 
void SetPosition (const sVec3< T > &aPos)
 Set the ellipsoid's position. More...
 
const sVec3< T > & GetPosition () const
 Get the ellipsoid's position. More...
 
const sVec3< T > & GetRadius () const
 Get the ellipsoid's radius. More...
 
void SetRadius (const sVec3< T > &aRadius)
 Set the ellipsoid's radius. More...
 
void SetXRadius (T aRadius)
 Set the ellipsoid's X radius. More...
 
void SetYRadius (T aRadius)
 Set the ellipsoid's Y radius. More...
 
void SetZRadius (T aRadius)
 Set the ellipsoid's Z radius. More...
 
sMatrix< T > & GetToUnitSphereMatrix (sMatrix< T > &aOut) const
 Get a matrix to convert to a unit sphere space. More...
 
sMatrix< T > & GetFromUnitSphereMatrix (sMatrix< T > &aOut) const
 Get a matrix to convert from a unit sphere space. More...
 
sVec3< T > & TangentPlaneNormal (sVec3< T > &aOut, const sVec3< T > &aP)
 Return a unit normal vector to tangent plane of the ellispsoid in the point. More...
 

Constructor & Destructor Documentation

cEllipsoid ( const sVec3< T > &  aPos,
const sVec3< T > &  aRadius 
)
cEllipsoid ( const sVec3< T > &  aRadius = sVec3<T>::One())

Member Function Documentation

void SetPosition ( const sVec3< T > &  aPos)

Set the ellipsoid's position.

const sVec3<T>& GetPosition ( ) const

Get the ellipsoid's position.

const sVec3<T>& GetRadius ( ) const

Get the ellipsoid's radius.

void SetRadius ( const sVec3< T > &  aRadius)

Set the ellipsoid's radius.

void SetXRadius ( aRadius)

Set the ellipsoid's X radius.

void SetYRadius ( aRadius)

Set the ellipsoid's Y radius.

void SetZRadius ( aRadius)

Set the ellipsoid's Z radius.

sMatrix<T>& GetToUnitSphereMatrix ( sMatrix< T > &  aOut) const

Get a matrix to convert to a unit sphere space.

sMatrix<T>& GetFromUnitSphereMatrix ( sMatrix< T > &  aOut) const

Get a matrix to convert from a unit sphere space.

sVec3<T>& TangentPlaneNormal ( sVec3< T > &  aOut,
const sVec3< T > &  aP 
)

Return a unit normal vector to tangent plane of the ellispsoid in the point.

Parameters
aOutis where the normal will be stored.
aPis point we want to compute normal at.
Returns
aOut.