RigsofRods
Soft-body Physics Simulation
Public Member Functions | Private Member Functions | Private Attributes
SkyX::VClouds::Ellipsoid Class Reference

Ellipsoid class x^2 y^2 z^2 / + / + / = 1 a^2 b^2 c^2. More...

#include <Ellipsoid.h>

Public Member Functions

 Ellipsoid (const int &a, const int &b, const int &c, const int &nx, const int &ny, const int &nz, const int &x, const int &y, const int &z, const Ogre::Real &DynLibManager=1.0f)
 Constructor. More...
 
 ~Ellipsoid ()
 Destructor. More...
 
void move (const int &Ax, const int &Ay, const int &Az)
 Move the ellipsoid. More...
 
const Ogre::Vector3 getProbabilities (const int &x, const int &y, const int &z) const
 Get probabilities at a point. More...
 
void updateProbabilities (DataManager::Cell ***c, const int &nx, const int &ny, const int &nz, const bool &delayedResponse=true)
 Update probabilities. More...
 
const bool isOutOfCells () const
 Determines if the ellipsoid is out of the cells domain and needs to be removed. More...
 
const Ogre::Vector3 getDimensions () const
 Get dimensions. More...
 
const Ogre::Vector3 getPosition () const
 Get position. More...
 
void setDimensions (const Ogre::Vector3 &Dimensions)
 Set dimensions. More...
 
void setPosition (const Ogre::Vector3 &Position)
 Set position. More...
 

Private Member Functions

const float _getLength (const int &x, const int &y, const int &z) const
 Get length. More...
 

Private Attributes

int mA
 Ellipsoid parameters. More...
 
int mB
 
int mC
 
int mA2
 
int mB2
 
int mC2
 
int mX
 Position. More...
 
int mY
 
int mZ
 
int mNx
 Cells size. More...
 
int mNy
 
int mNz
 
Ogre::Real mDensity
 Cloud density. More...
 

Detailed Description

Ellipsoid class x^2 y^2 z^2 / + / + / = 1 a^2 b^2 c^2.

Definition at line 38 of file Ellipsoid.h.

Constructor & Destructor Documentation

◆ Ellipsoid()

SkyX::VClouds::Ellipsoid::Ellipsoid ( const int &  a,
const int &  b,
const int &  c,
const int &  nx,
const int &  ny,
const int &  nz,
const int &  x,
const int &  y,
const int &  z,
const Ogre::Real &  DynLibManager = 1.0f 
)

Constructor.

Parameters
aA constant
bB constant
cC constant
nxX size
nyY size
nzZ size
xx Coord (position)
yy Coord (position)
zz Coord (position)
DensityCloud density

Definition at line 29 of file Ellipsoid.cpp.

◆ ~Ellipsoid()

SkyX::VClouds::Ellipsoid::~Ellipsoid ( )

Destructor.

Definition at line 42 of file Ellipsoid.cpp.

Member Function Documentation

◆ _getLength()

const float SkyX::VClouds::Ellipsoid::_getLength ( const int &  x,
const int &  y,
const int &  z 
) const
private

Get length.

Parameters
xx Coord
yy Coord
zz Coord
Returns
[0,1] range where 0 is the center of the ellipsoid and 1 the superfice

Definition at line 46 of file Ellipsoid.cpp.

+ Here is the caller graph for this function:

◆ getDimensions()

const Ogre::Vector3 SkyX::VClouds::Ellipsoid::getDimensions ( ) const
inline

Get dimensions.

Returns
Ellipsoid dimensions

Definition at line 93 of file Ellipsoid.h.

◆ getPosition()

const Ogre::Vector3 SkyX::VClouds::Ellipsoid::getPosition ( ) const
inline

Get position.

Returns
Position

Definition at line 101 of file Ellipsoid.h.

◆ getProbabilities()

const Ogre::Vector3 SkyX::VClouds::Ellipsoid::getProbabilities ( const int &  x,
const int &  y,
const int &  z 
) const

Get probabilities at a point.

Parameters
xx Coord
yy Coord
zz Coord
Returns
Probabilities (Hum, Ext, Act)

Definition at line 75 of file Ellipsoid.cpp.

+ Here is the call graph for this function:

◆ isOutOfCells()

const bool SkyX::VClouds::Ellipsoid::isOutOfCells ( ) const

Determines if the ellipsoid is out of the cells domain and needs to be removed.

Definition at line 121 of file Ellipsoid.cpp.

◆ move()

void SkyX::VClouds::Ellipsoid::move ( const int &  Ax,
const int &  Ay,
const int &  Az 
)

Move the ellipsoid.

Parameters
Axx increment
Ayy increment
Azz increment

Definition at line 116 of file Ellipsoid.cpp.

◆ setDimensions()

void SkyX::VClouds::Ellipsoid::setDimensions ( const Ogre::Vector3 &  Dimensions)

Set dimensions.

Parameters
DimensionsNew dimensions

Definition at line 133 of file Ellipsoid.cpp.

◆ setPosition()

void SkyX::VClouds::Ellipsoid::setPosition ( const Ogre::Vector3 &  Position)
inline

Set position.

Parameters
PositionNew position

Definition at line 114 of file Ellipsoid.h.

◆ updateProbabilities()

void SkyX::VClouds::Ellipsoid::updateProbabilities ( DataManager::Cell ***  c,
const int &  nx,
const int &  ny,
const int &  nz,
const bool &  delayedResponse = true 
)

Update probabilities.

Parameters
cCells
nxX complexity
nyY complexity
nzZ complexity
delayedResponsetrue to get a delayed response, updating only probabilities, false to also set clouds

Definition at line 82 of file Ellipsoid.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Field Documentation

◆ mA

int SkyX::VClouds::Ellipsoid::mA
private

Ellipsoid parameters.

Definition at line 131 of file Ellipsoid.h.

◆ mA2

int SkyX::VClouds::Ellipsoid::mA2
private

Definition at line 131 of file Ellipsoid.h.

◆ mB

int SkyX::VClouds::Ellipsoid::mB
private

Definition at line 131 of file Ellipsoid.h.

◆ mB2

int SkyX::VClouds::Ellipsoid::mB2
private

Definition at line 131 of file Ellipsoid.h.

◆ mC

int SkyX::VClouds::Ellipsoid::mC
private

Definition at line 131 of file Ellipsoid.h.

◆ mC2

int SkyX::VClouds::Ellipsoid::mC2
private

Definition at line 131 of file Ellipsoid.h.

◆ mDensity

Ogre::Real SkyX::VClouds::Ellipsoid::mDensity
private

Cloud density.

Definition at line 140 of file Ellipsoid.h.

◆ mNx

int SkyX::VClouds::Ellipsoid::mNx
private

Cells size.

Definition at line 137 of file Ellipsoid.h.

◆ mNy

int SkyX::VClouds::Ellipsoid::mNy
private

Definition at line 137 of file Ellipsoid.h.

◆ mNz

int SkyX::VClouds::Ellipsoid::mNz
private

Definition at line 137 of file Ellipsoid.h.

◆ mX

int SkyX::VClouds::Ellipsoid::mX
private

Position.

Definition at line 134 of file Ellipsoid.h.

◆ mY

int SkyX::VClouds::Ellipsoid::mY
private

Definition at line 134 of file Ellipsoid.h.

◆ mZ

int SkyX::VClouds::Ellipsoid::mZ
private

Definition at line 134 of file Ellipsoid.h.


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