RigsofRods
Soft-body Physics Simulation
Public Member Functions | Private Attributes
Hydrax::Decal Class Reference

Decal class. More...

#include <DecalsManager.h>

+ Collaboration diagram for Hydrax::Decal:

Public Member Functions

 Decal (Hydrax *h, const Ogre::String &TextureName, const int &Id)
 Constructor. More...
 
 ~Decal ()
 Destructor. More...
 
void registerPass (Ogre::Pass *_Pass)
 Register the decal int the specified pass. More...
 
void unregister ()
 Unregister from current technique. More...
 
const Ogre::String & getTextureName () const
 Get decal texture name. More...
 
const int & getId () const
 Get the decal Id. More...
 
Ogre::Frustum * getProjector ()
 Get the decal projector. More...
 
Ogre::SceneNode * getSceneNode ()
 Get the decal scene node. More...
 
Ogre::Pass * getRegisteredPass ()
 Get the pass the decal is in. More...
 
const Ogre::Vector2 & getPosition () const
 Get decal position. More...
 
const Ogre::Vector2 & getSize () const
 Get decal size. More...
 
const Ogre::Radian & getOrientation () const
 Get decal orientation. More...
 
const Ogre::Real & getTransparency () const
 Get decal transparency. More...
 
const bool & isVisible () const
 Is decal visile? More...
 
void setPosition (const Ogre::Vector2 &Position)
 Set decal position. More...
 
void setSize (const Ogre::Vector2 &Size)
 Set decal size. More...
 
void setOrientation (const Ogre::Radian &Orientation)
 Set decal orientation. More...
 
void setTransparency (const Ogre::Real &Transparency)
 Set decal transparency. More...
 
void setVisible (const bool &Visible)
 Set decal visibile or not. More...
 

Private Attributes

Ogre::String mTextureName
 Decal texture name. More...
 
int mId
 Decal Id. More...
 
Ogre::Frustum * mProjector
 Decal projector. More...
 
Ogre::SceneNode * mSceneNode
 Decal scene node. More...
 
Ogre::Pass * mRegisteredPass
 Registered pass. More...
 
Ogre::Vector2 mPosition
 Position. More...
 
Ogre::Vector2 mSize
 Size. More...
 
Ogre::Radian mOrientation
 Orientation. More...
 
Ogre::Real mTransparency
 Transparency. More...
 
bool mVisible
 Is decal visible? More...
 
HydraxmHydrax
 Hydrax parent pointer. More...
 

Detailed Description

Decal class.

Definition at line 42 of file DecalsManager.h.

Constructor & Destructor Documentation

◆ Decal()

Hydrax::Decal::Decal ( Hydrax h,
const Ogre::String &  TextureName,
const int &  Id 
)

Constructor.

Parameters
hHydrax parent pointer
TextureNameTexture name
IdDecal Id

Definition at line 31 of file DecalsManager.cpp.

+ Here is the call graph for this function:

◆ ~Decal()

Hydrax::Decal::~Decal ( )

Destructor.

Definition at line 55 of file DecalsManager.cpp.

+ Here is the call graph for this function:

Member Function Documentation

◆ getId()

const int& Hydrax::Decal::getId ( ) const
inline

Get the decal Id.

Returns
Decal Id

Definition at line 76 of file DecalsManager.h.

◆ getOrientation()

const Ogre::Radian& Hydrax::Decal::getOrientation ( ) const
inline

Get decal orientation.

Returns
Decal orientation

Definition at line 125 of file DecalsManager.h.

◆ getPosition()

const Ogre::Vector2& Hydrax::Decal::getPosition ( ) const
inline

Get decal position.

Returns
Decal position

Definition at line 109 of file DecalsManager.h.

◆ getProjector()

Ogre::Frustum* Hydrax::Decal::getProjector ( )
inline

Get the decal projector.

Returns
Projector frustum

Definition at line 84 of file DecalsManager.h.

◆ getRegisteredPass()

Ogre::Pass* Hydrax::Decal::getRegisteredPass ( )
inline

Get the pass the decal is in.

Returns
Registered pass
Remarks
return NULL if decal isn't registered

Definition at line 101 of file DecalsManager.h.

◆ getSceneNode()

Ogre::SceneNode* Hydrax::Decal::getSceneNode ( )
inline

Get the decal scene node.

Returns
Decal scene node

Definition at line 92 of file DecalsManager.h.

◆ getSize()

const Ogre::Vector2& Hydrax::Decal::getSize ( ) const
inline

Get decal size.

Returns
Decal size

Definition at line 117 of file DecalsManager.h.

◆ getTextureName()

const Ogre::String& Hydrax::Decal::getTextureName ( ) const
inline

Get decal texture name.

Returns
Decal texture name

Definition at line 68 of file DecalsManager.h.

◆ getTransparency()

const Ogre::Real& Hydrax::Decal::getTransparency ( ) const
inline

Get decal transparency.

Returns
Decal transparency

Definition at line 133 of file DecalsManager.h.

◆ isVisible()

const bool& Hydrax::Decal::isVisible ( ) const
inline

Is decal visile?

Returns
true if decal is visible

Definition at line 141 of file DecalsManager.h.

◆ registerPass()

void Hydrax::Decal::registerPass ( Ogre::Pass *  _Pass)

Register the decal int the specified pass.

Parameters
_PassPass to be registred

Definition at line 64 of file DecalsManager.cpp.

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

◆ setOrientation()

void Hydrax::Decal::setOrientation ( const Ogre::Radian &  Orientation)

Set decal orientation.

Parameters
OrientationDecal orientation

Definition at line 109 of file DecalsManager.cpp.

+ Here is the caller graph for this function:

◆ setPosition()

void Hydrax::Decal::setPosition ( const Ogre::Vector2 &  Position)

Set decal position.

Parameters
PositionDecal position

Definition at line 92 of file DecalsManager.cpp.

+ Here is the caller graph for this function:

◆ setSize()

void Hydrax::Decal::setSize ( const Ogre::Vector2 &  Size)

Set decal size.

Parameters
SizeDecal size in world coordinates

Definition at line 99 of file DecalsManager.cpp.

+ Here is the caller graph for this function:

◆ setTransparency()

void Hydrax::Decal::setTransparency ( const Ogre::Real &  Transparency)

Set decal transparency.

Parameters
TransparencyDecal transparency in [0,1] range
Remarks
0 = Full transparent, 1 = Full opacity

Definition at line 116 of file DecalsManager.cpp.

◆ setVisible()

void Hydrax::Decal::setVisible ( const bool &  Visible)

Set decal visibile or not.

Parameters
Visibletrue if yes, false if not

Definition at line 127 of file DecalsManager.cpp.

+ Here is the call graph for this function:

◆ unregister()

void Hydrax::Decal::unregister ( )

Unregister from current technique.

Definition at line 83 of file DecalsManager.cpp.

+ Here is the caller graph for this function:

Field Documentation

◆ mHydrax

Hydrax* Hydrax::Decal::mHydrax
private

Hydrax parent pointer.

Definition at line 196 of file DecalsManager.h.

◆ mId

int Hydrax::Decal::mId
private

Decal Id.

Definition at line 176 of file DecalsManager.h.

◆ mOrientation

Ogre::Radian Hydrax::Decal::mOrientation
private

Orientation.

Definition at line 189 of file DecalsManager.h.

◆ mPosition

Ogre::Vector2 Hydrax::Decal::mPosition
private

Position.

Definition at line 185 of file DecalsManager.h.

◆ mProjector

Ogre::Frustum* Hydrax::Decal::mProjector
private

Decal projector.

Definition at line 178 of file DecalsManager.h.

◆ mRegisteredPass

Ogre::Pass* Hydrax::Decal::mRegisteredPass
private

Registered pass.

Definition at line 182 of file DecalsManager.h.

◆ mSceneNode

Ogre::SceneNode* Hydrax::Decal::mSceneNode
private

Decal scene node.

Definition at line 180 of file DecalsManager.h.

◆ mSize

Ogre::Vector2 Hydrax::Decal::mSize
private

Size.

Definition at line 187 of file DecalsManager.h.

◆ mTextureName

Ogre::String Hydrax::Decal::mTextureName
private

Decal texture name.

Definition at line 174 of file DecalsManager.h.

◆ mTransparency

Ogre::Real Hydrax::Decal::mTransparency
private

Transparency.

Definition at line 191 of file DecalsManager.h.

◆ mVisible

bool Hydrax::Decal::mVisible
private

Is decal visible?

Definition at line 193 of file DecalsManager.h.


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