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

#include <GeometryManager.h>

+ Collaboration diagram for SkyX::VClouds::GeometryManager:

Public Member Functions

 GeometryManager (VClouds *vc)
 Constructor. More...
 
 ~GeometryManager ()
 Destructor. More...
 
void create (const Ogre::Vector2 &Height, const float &Radius, const Ogre::Radian &Alpha, const Ogre::Radian &Beta, const int &NumberOfBlocks, const int &Na, const int &Nb, const int &Nc)
 Create. More...
 
void remove ()
 Remove. More...
 
void update (const Ogre::Real &timeSinceLastFrame)
 Update, to be invoked per frame. More...
 
void updateGeometry (Ogre::Camera *c, const Ogre::Real &timeSinceLastCameraFrame)
 Update geoemtry. More...
 
const bool & isCreated () const
 Has been create() already called? More...
 
Ogre::SceneNode * getSceneNode ()
 Get scene node. More...
 
const Ogre::Vector2 getHeight () const
 Get height (x = Altitude over the camera, y: Field height (both in world coordinates)) More...
 
void _setMaterialName (const Ogre::String &mn)
 Set material name. More...
 
void _updateRenderQueueGroup (const Ogre::uint8 &rqg)
 Update render queue group. More...
 
const Ogre::Vector3 _getCurrentDistance () const
 Get current camera to cloud field distance. More...
 

Private Member Functions

void _createGeometry ()
 Create geometry. More...
 
void _updateGeometry (Ogre::Camera *c, const Ogre::Real &timeSinceLastFrame)
 Update geometry. More...
 

Private Attributes

bool mCreated
 Has been create() already called? More...
 
Ogre::Vector2 mHeight
 Height: x = Altitude over the camera, y: Field height (both in world coordinates) More...
 
Ogre::Radian mAlpha
 Angles. More...
 
Ogre::Radian mBeta
 
float mRadius
 Radius. More...
 
Ogre::Radian mPhi
 Azimutal angle per block. More...
 
int mNumberOfBlocks
 Number of blocks. More...
 
int mNa
 Number of slices per geometry zone. More...
 
int mNb
 
int mNc
 
float mA
 A, B and C radius. More...
 
float mB
 
float mC
 
Ogre::Vector2 mWorldOffset
 World coords offset. More...
 
std::vector< GeometryBlock * > mGeometryBlocks
 Geometry blocks. More...
 
Ogre::SceneNode * mSceneNode
 Scene node. More...
 
Ogre::Vector3 mCurrentDistance
 Current camera-clouds distance. More...
 
VCloudsmVClouds
 VClouds pointer. More...
 

Detailed Description

Definition at line 35 of file GeometryManager.h.

Constructor & Destructor Documentation

◆ GeometryManager()

SkyX::VClouds::GeometryManager::GeometryManager ( VClouds vc)

Constructor.

Parameters
vcVClouds pointer

Definition at line 31 of file GeometryManager.cpp.

◆ ~GeometryManager()

SkyX::VClouds::GeometryManager::~GeometryManager ( )

Destructor.

Definition at line 47 of file GeometryManager.cpp.

+ Here is the call graph for this function:

Member Function Documentation

◆ _createGeometry()

void SkyX::VClouds::GeometryManager::_createGeometry ( )
private

Create geometry.

Definition at line 133 of file GeometryManager.cpp.

+ Here is the caller graph for this function:

◆ _getCurrentDistance()

const Ogre::Vector3 SkyX::VClouds::GeometryManager::_getCurrentDistance ( ) const
inline

Get current camera to cloud field distance.

Returns
Current camera to cloud field distance
Remarks
Only for internal use

Definition at line 116 of file GeometryManager.h.

+ Here is the caller graph for this function:

◆ _setMaterialName()

void SkyX::VClouds::GeometryManager::_setMaterialName ( const Ogre::String &  mn)

Set material name.

Parameters
mnMaterial name
Remarks
Only for internal use

Definition at line 117 of file GeometryManager.cpp.

+ Here is the caller graph for this function:

◆ _updateGeometry()

void SkyX::VClouds::GeometryManager::_updateGeometry ( Ogre::Camera *  c,
const Ogre::Real &  timeSinceLastFrame 
)
private

Update geometry.

Parameters
cCamera
timeSinceLastFrameTime since last frame

Definition at line 149 of file GeometryManager.cpp.

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

◆ _updateRenderQueueGroup()

void SkyX::VClouds::GeometryManager::_updateRenderQueueGroup ( const Ogre::uint8 &  rqg)

Update render queue group.

Parameters
rqgRender queue group
Remarks
Only for internal use. Use VClouds::setRenderQueueGroups(...) instead.

Definition at line 125 of file GeometryManager.cpp.

+ Here is the caller graph for this function:

◆ create()

void SkyX::VClouds::GeometryManager::create ( const Ogre::Vector2 &  Height,
const float &  Radius,
const Ogre::Radian &  Alpha,
const Ogre::Radian &  Beta,
const int &  NumberOfBlocks,
const int &  Na,
const int &  Nb,
const int &  Nc 
)

Create.

Parameters
Heightx = Field altitude, y: Field height (both in world coordinates)
RadiusRadius
AlphaAlpha angle
BetaBeta angle
NumberOfBlocksNumber of geometry blocks
NaNumber of slices in A zone
NbNumber of slices in B zone
NcNumber of slices in C zone

Definition at line 52 of file GeometryManager.cpp.

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

◆ getHeight()

const Ogre::Vector2 SkyX::VClouds::GeometryManager::getHeight ( ) const
inline

Get height (x = Altitude over the camera, y: Field height (both in world coordinates))

Returns
Height (x = Altitude over the camera, y: Field height (both in world coordinates))

Definition at line 95 of file GeometryManager.h.

+ Here is the caller graph for this function:

◆ getSceneNode()

Ogre::SceneNode* SkyX::VClouds::GeometryManager::getSceneNode ( )
inline

Get scene node.

Returns
Scene node

Definition at line 87 of file GeometryManager.h.

+ Here is the caller graph for this function:

◆ isCreated()

const bool& SkyX::VClouds::GeometryManager::isCreated ( ) const
inline

Has been create() already called?

Returns
true if created() have been already called, false if not

Definition at line 79 of file GeometryManager.h.

◆ remove()

void SkyX::VClouds::GeometryManager::remove ( )

Remove.

Definition at line 72 of file GeometryManager.cpp.

+ Here is the caller graph for this function:

◆ update()

void SkyX::VClouds::GeometryManager::update ( const Ogre::Real &  timeSinceLastFrame)

Update, to be invoked per frame.

Parameters
timeSinceLastFrameTime since last frame

Definition at line 94 of file GeometryManager.cpp.

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

◆ updateGeometry()

void SkyX::VClouds::GeometryManager::updateGeometry ( Ogre::Camera *  c,
const Ogre::Real &  timeSinceLastCameraFrame 
)

Update geoemtry.

Parameters
cCamera
timeSinceLastCameraFrameTime since last CAMERA frame

Definition at line 104 of file GeometryManager.cpp.

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

Field Documentation

◆ mA

float SkyX::VClouds::GeometryManager::mA
private

A, B and C radius.

Definition at line 148 of file GeometryManager.h.

◆ mAlpha

Ogre::Radian SkyX::VClouds::GeometryManager::mAlpha
private

Angles.

Definition at line 138 of file GeometryManager.h.

◆ mB

float SkyX::VClouds::GeometryManager::mB
private

Definition at line 148 of file GeometryManager.h.

◆ mBeta

Ogre::Radian SkyX::VClouds::GeometryManager::mBeta
private

Definition at line 138 of file GeometryManager.h.

◆ mC

float SkyX::VClouds::GeometryManager::mC
private

Definition at line 148 of file GeometryManager.h.

◆ mCreated

bool SkyX::VClouds::GeometryManager::mCreated
private

Has been create() already called?

Definition at line 133 of file GeometryManager.h.

◆ mCurrentDistance

Ogre::Vector3 SkyX::VClouds::GeometryManager::mCurrentDistance
private

Current camera-clouds distance.

Definition at line 160 of file GeometryManager.h.

◆ mGeometryBlocks

std::vector<GeometryBlock*> SkyX::VClouds::GeometryManager::mGeometryBlocks
private

Geometry blocks.

Definition at line 154 of file GeometryManager.h.

◆ mHeight

Ogre::Vector2 SkyX::VClouds::GeometryManager::mHeight
private

Height: x = Altitude over the camera, y: Field height (both in world coordinates)

Definition at line 136 of file GeometryManager.h.

◆ mNa

int SkyX::VClouds::GeometryManager::mNa
private

Number of slices per geometry zone.

Definition at line 146 of file GeometryManager.h.

◆ mNb

int SkyX::VClouds::GeometryManager::mNb
private

Definition at line 146 of file GeometryManager.h.

◆ mNc

int SkyX::VClouds::GeometryManager::mNc
private

Definition at line 146 of file GeometryManager.h.

◆ mNumberOfBlocks

int SkyX::VClouds::GeometryManager::mNumberOfBlocks
private

Number of blocks.

Definition at line 144 of file GeometryManager.h.

◆ mPhi

Ogre::Radian SkyX::VClouds::GeometryManager::mPhi
private

Azimutal angle per block.

Definition at line 142 of file GeometryManager.h.

◆ mRadius

float SkyX::VClouds::GeometryManager::mRadius
private

Radius.

Definition at line 140 of file GeometryManager.h.

◆ mSceneNode

Ogre::SceneNode* SkyX::VClouds::GeometryManager::mSceneNode
private

Scene node.

Definition at line 157 of file GeometryManager.h.

◆ mVClouds

VClouds* SkyX::VClouds::GeometryManager::mVClouds
private

VClouds pointer.

Definition at line 163 of file GeometryManager.h.

◆ mWorldOffset

Ogre::Vector2 SkyX::VClouds::GeometryManager::mWorldOffset
private

World coords offset.

Definition at line 151 of file GeometryManager.h.


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