GFXD3D9StateBlock Class Reference

#include <gfxD3D9StateBlock.h>

Inheritance diagram for GFXD3D9StateBlock:

Inheritance graph
[legend]
List of all members.

Public Member Functions

 GFXD3D9StateBlock (const GFXStateBlockDesc &desc, LPDIRECT3DDEVICE9 d3dDevice)
virtual ~GFXD3D9StateBlock ()
void activate (GFXD3D9StateBlock *oldState)
 Called by D3D9 device to active this state block.
virtual U32 getHashValue () const
 Returns the hash value of the desc that created this block.
virtual const GFXStateBlockDescgetDesc () const
 Returns a GFXStateBlockDesc that this block represents.
virtual void zombify ()
 When called the resource should destroy all device sensitive information (e.g. D3D resources in D3DPOOL_DEFAULT.
virtual void resurrect ()
 When called the resource should restore all device sensitive information destroyed by zombify().

Private Attributes

GFXStateBlockDesc mDesc
U32 mCachedHashValue
LPDIRECT3DDEVICE9 mD3DDevice
 Handle for D3DDevice.
U32 mColorMask
U32 mZBias
U32 mZSlopeBias

Constructor & Destructor Documentation

GFXD3D9StateBlock::GFXD3D9StateBlock ( const GFXStateBlockDesc desc,
LPDIRECT3DDEVICE9  d3dDevice 
)

virtual GFXD3D9StateBlock::~GFXD3D9StateBlock (  )  [virtual]


Member Function Documentation

void GFXD3D9StateBlock::activate ( GFXD3D9StateBlock oldState  ) 

Called by D3D9 device to active this state block.

Parameters:
oldState The current state, used to make sure we don't set redundant states on the device. Pass NULL to reset all states.

virtual U32 GFXD3D9StateBlock::getHashValue (  )  const [virtual]

Returns the hash value of the desc that created this block.

Implements GFXStateBlock.

virtual const GFXStateBlockDesc& GFXD3D9StateBlock::getDesc (  )  const [virtual]

Returns a GFXStateBlockDesc that this block represents.

Implements GFXStateBlock.

virtual void GFXD3D9StateBlock::zombify (  )  [inline, virtual]

When called the resource should destroy all device sensitive information (e.g. D3D resources in D3DPOOL_DEFAULT.

Implements GFXResource.

virtual void GFXD3D9StateBlock::resurrect (  )  [inline, virtual]

When called the resource should restore all device sensitive information destroyed by zombify().

Implements GFXResource.


Member Data Documentation

LPDIRECT3DDEVICE9 GFXD3D9StateBlock::mD3DDevice [private]

Handle for D3DDevice.