Drag[en]gine Game Engine  1.0
deBillboard Class Reference

Billboard Resource. Billboards are rectangular objects that are different from components in that they are flat and oriented relative to the camera. Billboards can be locked in which case they are oriented along an axis or free in which case they are oriented around their position. Furthermore billboards are either spherical in which case they are oriented relative to the camera position or planar in which case they are oriented relative to the camera near plane. The image of the billboard is either a skin or a dynamic skin and has a 2 dimensional size as well as a 2 dimensional offset relative to the position and orientation axis. The y component of the size and offset moves along the orientation axis and therefore is aligned along the up direction in the camera view. The x component moves perpendicular to the orientation axis relative to the camera view and therefore is aligned along the right direction in the camera view. By default billboards are axis oriented with a world-up axis and are spherical. More...

#include <deBillboard.h>

Inheritance diagram for deBillboard:
deResource deObject

Public Member Functions

Management
const decDVectorGetPosition () const
 
void SetPosition (const decDVector &position)
 
const decVectorGetAxis () const
 
void SetAxis (const decVector &axis)
 
const decVector2GetSize () const
 
void SetSize (const decVector2 &size)
 
const decVector2GetOffset () const
 
void SetOffset (const decVector2 &offset)
 
deSkinGetSkin () const
 
void SetSkin (deSkin *skin)
 
deDynamicSkinGetDynamicSkin () const
 
void SetDynamicSkin (deDynamicSkin *dynamicSkin)
 
bool GetLocked () const
 
void SetLocked (bool locked)
 
bool GetSpherical () const
 
void SetSpherical (bool spherical)
 
bool GetSizeFixedToScreen () const
 
void SetSizeFixedToScreen (bool sizeFixedToScreen)
 
bool GetVisible () const
 
void SetVisible (bool visible)
 
System Peers
deBaseGraphicBillboardGetGraphicPeer () const
 
void SetGraphicPeer (deBaseGraphicBillboard *peer)
 
Linked List
deWorldGetParentWorld () const
 
void SetParentWorld (deWorld *world)
 
deBillboardGetLLWorldPrev () const
 
void SetLLWorldPrev (deBillboard *billboard)
 
deBillboardGetLLWorldNext () const
 
void SetLLWorldNext (deBillboard *billboard)
 
- Public Member Functions inherited from deResource
deResourceManagerGetResourceManager () const
 Resource manager or NULL if resource is leaking. More...
 
deEngineGetEngine () const
 Game engine object from resource manager. More...
 
deResourceGetLLManagerPrev () const
 Previous resource in the resource manager linked list. More...
 
void SetLLManagerPrev (deResource *resource)
 Set next resource in the resource manager linked list. More...
 
deResourceGetLLManagerNext () const
 Next resource in the resource manager linked list. More...
 
void SetLLManagerNext (deResource *resource)
 Set next resource in the resource manager linked list. More...
 
void MarkLeaking ()
 Marks the resource leaking. More...
 
 deResource (deResourceManager *resourceManager)
 Create resource. More...
 
- Public Member Functions inherited from deObject
int GetRefCount () const
 Reference count. More...
 
void AddReference ()
 Add reference increasing reference count by 1. More...
 
void FreeReference ()
 Decrease reference count by one and delete object if count reaches 0. More...
 
 deObject ()
 Create object with reference count of 1. More...
 

Constructors and Destructors

 deBillboard (deBillboardManager *manager)
 
virtual ~deBillboard ()
 Cleas up billboard. More...
 

Additional Inherited Members

- Protected Member Functions inherited from deResource
virtual ~deResource ()
 Clean up resource. More...
 
- Protected Member Functions inherited from deObject
virtual ~deObject ()
 Clean up object. More...
 

Detailed Description

Billboard Resource. Billboards are rectangular objects that are different from components in that they are flat and oriented relative to the camera. Billboards can be locked in which case they are oriented along an axis or free in which case they are oriented around their position. Furthermore billboards are either spherical in which case they are oriented relative to the camera position or planar in which case they are oriented relative to the camera near plane. The image of the billboard is either a skin or a dynamic skin and has a 2 dimensional size as well as a 2 dimensional offset relative to the position and orientation axis. The y component of the size and offset moves along the orientation axis and therefore is aligned along the up direction in the camera view. The x component moves perpendicular to the orientation axis relative to the camera view and therefore is aligned along the right direction in the camera view. By default billboards are axis oriented with a world-up axis and are spherical.

Author
Pl├╝ss Roland
Version
1.0
Date
2010

Constructor & Destructor Documentation

◆ deBillboard()

deBillboard::deBillboard ( deBillboardManager manager)

Creates a new billboard.

◆ ~deBillboard()

virtual deBillboard::~deBillboard ( )
protectedvirtual

Cleas up billboard.

Note
Subclasses should set their destructor protected too to avoid users accidently deleting a reference counted object through the object pointer. Only FreeReference() is allowed to delete the object.

Member Function Documentation

◆ GetAxis()

const decVector& deBillboard::GetAxis ( ) const
inline

Retrieves the axis.

References SetAxis().

◆ GetDynamicSkin()

deDynamicSkin* deBillboard::GetDynamicSkin ( ) const
inline

Retrieves the dynamic skin or NULL if not assigned.

References SetDynamicSkin().

◆ GetGraphicPeer()

deBaseGraphicBillboard* deBillboard::GetGraphicPeer ( ) const
inline

Retrieves the graphic system peer or NULL if not set.

References SetGraphicPeer().

◆ GetLLWorldNext()

deBillboard* deBillboard::GetLLWorldNext ( ) const
inline

Retrieves the next billboard in the parent world linked list.

References SetLLWorldNext().

◆ GetLLWorldPrev()

deBillboard* deBillboard::GetLLWorldPrev ( ) const
inline

Retrieves the previous billboard in the parent world linked list.

References SetLLWorldPrev().

◆ GetLocked()

bool deBillboard::GetLocked ( ) const
inline

Determines if the billboard is locked.

References SetLocked().

◆ GetOffset()

const decVector2& deBillboard::GetOffset ( ) const
inline

Retrieves the offset.

References SetOffset().

◆ GetParentWorld()

deWorld* deBillboard::GetParentWorld ( ) const
inline

Retrieves the parent world or NULL.

References SetParentWorld().

◆ GetPosition()

const decDVector& deBillboard::GetPosition ( ) const
inline

Retrieves the position.

References SetPosition().

◆ GetSize()

const decVector2& deBillboard::GetSize ( ) const
inline

Retrieves the size.

References SetSize().

◆ GetSizeFixedToScreen()

bool deBillboard::GetSizeFixedToScreen ( ) const
inline

Determines if the billboard size is fixed to the screen size.

References SetSizeFixedToScreen().

◆ GetSkin()

deSkin* deBillboard::GetSkin ( ) const
inline

Retrieves the skin or NULL if not assigned.

References SetSkin().

◆ GetSpherical()

bool deBillboard::GetSpherical ( ) const
inline

Determines if the billboard is spherical.

References SetSpherical().

◆ GetVisible()

bool deBillboard::GetVisible ( ) const
inline

Determines if the billboard is visible.

References SetVisible().

◆ SetAxis()

void deBillboard::SetAxis ( const decVector axis)

Sets the axis.

Referenced by GetAxis().

◆ SetDynamicSkin()

void deBillboard::SetDynamicSkin ( deDynamicSkin dynamicSkin)

Sets the dynamic skin.

Referenced by GetDynamicSkin().

◆ SetGraphicPeer()

void deBillboard::SetGraphicPeer ( deBaseGraphicBillboard peer)

Sets the graphic system peer or NULL if not set.

Referenced by GetGraphicPeer().

◆ SetLLWorldNext()

void deBillboard::SetLLWorldNext ( deBillboard billboard)

Sets the next billboard in the parent world linked list.

Referenced by GetLLWorldNext().

◆ SetLLWorldPrev()

void deBillboard::SetLLWorldPrev ( deBillboard billboard)

Sets the next billboard in the parent world linked list.

Referenced by GetLLWorldPrev().

◆ SetLocked()

void deBillboard::SetLocked ( bool  locked)

Sets the billboard is locked.

Referenced by GetLocked().

◆ SetOffset()

void deBillboard::SetOffset ( const decVector2 offset)

Sets the offset.

Referenced by GetOffset().

◆ SetParentWorld()

void deBillboard::SetParentWorld ( deWorld world)

Sets the parent world or NULL.

Referenced by GetParentWorld().

◆ SetPosition()

void deBillboard::SetPosition ( const decDVector position)

Sets the position.

Referenced by GetPosition().

◆ SetSize()

void deBillboard::SetSize ( const decVector2 size)

Sets the size.

Referenced by GetSize().

◆ SetSizeFixedToScreen()

void deBillboard::SetSizeFixedToScreen ( bool  sizeFixedToScreen)

Sets if the billboard size is fixed to the screen size.

Referenced by GetSizeFixedToScreen().

◆ SetSkin()

void deBillboard::SetSkin ( deSkin skin)

Sets the skin.

Referenced by GetSkin().

◆ SetSpherical()

void deBillboard::SetSpherical ( bool  spherical)

Sets if the billboard is spherical.

Referenced by GetSpherical().

◆ SetVisible()

void deBillboard::SetVisible ( bool  visible)

Sets if the billboard is visible.

Referenced by GetVisible().


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