raSystem  1.0 bata
raGroup Class Reference

#include <raGroupe.h>

Inheritance diagram for raGroup:
raVisual raRender IRAMesh

Public Member Functions

 raGroup (raSmartPointer< raDirectX > dx, IRAMesh *pVisual, int numInstancesToDraw=0, bool bAlpha=false, bool bAdditive=false, bool bDepthDisable=false, D3D11_FILL_MODE fillMode=D3D11_FILL_SOLID, D3D11_CULL_MODE cullMode=D3D11_CULL_BACK)
 
virtual ~raGroup (void)
 
virtual bool Create ()
 
virtual void Destroy ()
 
virtual bool CreateMesh ()
 
virtual bool DestroyMesh ()
 
virtual bool RenderMesh (LPCSTR techniqueName="")
 
virtual void SetWorldMatrix (const raMatrix &value)
 
virtual void SetWorldMatrix (const raMatrix &value, int instanceNo)
 
virtual const raMatrixGetWorldMatrix (int instanceNo)
 
virtual bool Intersects (CONST raVector3 *pRayPos, CONST raVector3 *pRayDir, FLOAT *pDist)
 
virtual ID3D11Buffer * GetVertexBuffer ()
 
virtual ID3D11Buffer * GetIndexBuffer ()
 
virtual UINT GetStrideSize ()
 
virtual D3D11_PRIMITIVE_TOPOLOGY GetPrimitiveTopology (UINT n)
 
virtual UINT GetNumSubsets ()
 
virtual SDKMESH_SUBSETGetSubset (UINT n)
 
void CreateRandomMatrices (float scaleX=1.0f, float scaleY=1.0f, float scaleZ=1.0f, float offsetY=0.0f)
 
UINT AddInstance (const raMatrix &world)
 
IRAMeshGetVisual (void)
 
- Public Member Functions inherited from raVisual
 raVisual (raSmartPointer< raDirectX > dx, bool bAlpha=false, bool bAdditive=false, bool bDepthDisable=false, D3D11_FILL_MODE fillMode=D3D11_FILL_SOLID, D3D11_CULL_MODE cullMode=D3D11_CULL_BACK)
 
 ~raVisual (void)
 
virtual void CreateEffectVariables ()
 
virtual void DestroyEffectVariables ()
 
virtual void SetupEffectVariables (const raMatrix &pView, const raMatrix &pProj, const raLight *pLight)
 
virtual bool Render (UINT drawOrder, const raMatrix &pView, const raMatrix &pProj, const raLight *pLight, LPCSTR techniqueName="")
 
virtual void CreateMaterials ()
 
virtual void DestroyMaterials ()
 
bool SetState ()
 
bool RestoreState ()
 
virtual const D3D11_INPUT_ELEMENT_DESC * GetVertexLayout ()
 
virtual UINT GetNumElements ()
 
virtual DXGI_FORMAT GetIndexBufferFormat ()
 
virtual UINT GetNumMaterials ()
 
virtual raMaterialGetMaterial (UINT n)
 
void SetMaterial (UINT n, raMaterial *pMaterial)
 
void SetMaterial_1 (UINT n, raMaterial *pMaterial)
 
void SetTexture (UINT n, LPCSTR textureFileName)
 
void SetTexture_1 (UINT n, LPCSTR textureFileName)
 
virtual void SetVisible (bool bVisible)
 
virtual void SetDrawOder (UINT Value)
 
virtual void SetSelected (bool bSelected)
 
virtual const float GetBoundingsphereRadius ()
 
- Public Member Functions inherited from raRender
 raRender (raSmartPointer< raDirectX > dx, const raMatrix *mWorld=NULL, LPCSTR Name="Render")
 
virtual ~raRender (void)
 
virtual bool Update (float fTime, float fRunTime)
 
LPCSTR GetName ()
 
void SetName (LPCSTR Name)
 
virtual raMatrixGetWorldMatrix (void)
 
virtual bool Intersects (const raVector3 *pRayPos, const raVector3 *pRayDir, float *pDist)
 
- Public Member Functions inherited from IRAMesh
virtual ~IRAMesh ()
 

Protected Member Functions

virtual void LoadInstanceData ()
 
virtual bool CreateVertexLayout ()
 
void InitInstanceMatrices ()
 
void UpdateInstanceMatrices ()
 
- Protected Member Functions inherited from raVisual
bool CreateAlphaBlendState ()
 
bool CreateDepthStencilState ()
 
bool CreateRasterizerState ()
 

Protected Attributes

IRAMeshm_pVisual
 
raMatrix m_InstanceMatrices [MAX_INSTANCES]
 
int m_iNumInstances
 
int m_iNumInstancesToDraw
 
raMatrixm_pInstanceList
 
ID3D11Buffer * m_pInstanceData
 
- Protected Attributes inherited from raVisual
UINT m_DrawOder
 
DWORD m_numMaterials
 
raMaterial ** m_pMaterials
 
raSmartPointer< raDirectXm_dx
 
ID3D11InputLayout * m_pVertexLayout
 
ID3D11BlendState * m_pAlphaBlendState
 
ID3D11BlendState * m_pOldAlphaBlendState
 
ID3D11DepthStencilState * m_pDepthStencilState
 
ID3D11DepthStencilState * m_pOldDepthStencilState
 
ID3D11RasterizerState * m_pRasterState
 
ID3D11RasterizerState * m_pOldRasterState
 
bool m_bVisible
 
bool m_bAlpha
 
bool m_bAdditive
 
float m_blendFactor [4]
 
UINT m_sampleMask
 
bool m_bDepthDisable
 
UINT m_StencilRef
 
D3D11_FILL_MODE m_FillMode
 
D3D11_CULL_MODE m_CullMode
 
DWORD m_numSubsets
 
SDKMESH_SUBSETm_pSubsets
 
- Protected Attributes inherited from raRender
raSmartPointer< raDirectXm_dx
 
raMatrix m_World
 
LPCSTR m_Name
 

Additional Inherited Members

- Public Attributes inherited from raVisual
raVector3 m_bbMin
 
raVector3 m_bbMax
 
- Static Public Attributes inherited from raVisual
static raString EffectfileName
 
static raString TechniqueName
 
static raString TexturedTechniqueName
 
static raString SkinnedEffectfileName
 
static raString SkinnedEffectfileName2
 
static raString SkinnedTechniqueName
 
static raString SkinnedTexturedTechniqueName
 

Detailed Description

Definition at line 5 of file raGroupe.h.

Constructor & Destructor Documentation

◆ raGroup()

raGroup::raGroup ( raSmartPointer< raDirectX dx,
IRAMesh pVisual,
int  numInstancesToDraw = 0,
bool  bAlpha = false,
bool  bAdditive = false,
bool  bDepthDisable = false,
D3D11_FILL_MODE  fillMode = D3D11_FILL_SOLID,
D3D11_CULL_MODE  cullMode = D3D11_CULL_BACK 
)

Definition at line 5 of file raGroupe.cpp.

◆ ~raGroup()

raGroup::~raGroup ( void  )
virtual

Definition at line 17 of file raGroupe.cpp.

Member Function Documentation

◆ AddInstance()

UINT raGroup::AddInstance ( const raMatrix world)

Definition at line 155 of file raGroupe.cpp.

◆ Create()

bool raGroup::Create ( void  )
virtual

Reimplemented from raVisual.

Definition at line 77 of file raGroupe.cpp.

◆ CreateMesh()

virtual bool raGroup::CreateMesh ( void  )
inlinevirtual

Implements IRAMesh.

Definition at line 17 of file raGroupe.h.

◆ CreateRandomMatrices()

void raGroup::CreateRandomMatrices ( float  scaleX = 1.0f,
float  scaleY = 1.0f,
float  scaleZ = 1.0f,
float  offsetY = 0.0f 
)

Definition at line 29 of file raGroupe.cpp.

◆ CreateVertexLayout()

bool raGroup::CreateVertexLayout ( )
protectedvirtual

Reimplemented from raVisual.

Definition at line 37 of file raGroupe.cpp.

◆ Destroy()

void raGroup::Destroy ( void  )
virtual

Reimplemented from raVisual.

Definition at line 104 of file raGroupe.cpp.

◆ DestroyMesh()

virtual bool raGroup::DestroyMesh ( )
inlinevirtual

Implements IRAMesh.

Definition at line 18 of file raGroupe.h.

◆ GetIndexBuffer()

virtual ID3D11Buffer* raGroup::GetIndexBuffer ( )
inlinevirtual

Implements IRAMesh.

Definition at line 26 of file raGroupe.h.

◆ GetNumSubsets()

virtual UINT raGroup::GetNumSubsets ( )
inlinevirtual

Implements IRAMesh.

Definition at line 29 of file raGroupe.h.

◆ GetPrimitiveTopology()

virtual D3D11_PRIMITIVE_TOPOLOGY raGroup::GetPrimitiveTopology ( UINT  n)
inlinevirtual

Implements IRAMesh.

Definition at line 28 of file raGroupe.h.

◆ GetStrideSize()

virtual UINT raGroup::GetStrideSize ( )
inlinevirtual

Reimplemented from raVisual.

Definition at line 27 of file raGroupe.h.

◆ GetSubset()

virtual SDKMESH_SUBSET* raGroup::GetSubset ( UINT  n)
inlinevirtual

Implements IRAMesh.

Definition at line 30 of file raGroupe.h.

◆ GetVertexBuffer()

virtual ID3D11Buffer* raGroup::GetVertexBuffer ( )
inlinevirtual

Implements IRAMesh.

Definition at line 25 of file raGroupe.h.

◆ GetVisual()

IRAMesh* raGroup::GetVisual ( void  )
inline

Definition at line 35 of file raGroupe.h.

◆ GetWorldMatrix()

const raMatrix * raGroup::GetWorldMatrix ( int  instanceNo)
virtual

Definition at line 178 of file raGroupe.cpp.

◆ InitInstanceMatrices()

void raGroup::InitInstanceMatrices ( )
protected

Definition at line 21 of file raGroupe.cpp.

◆ Intersects()

virtual bool raGroup::Intersects ( CONST raVector3 pRayPos,
CONST raVector3 pRayDir,
FLOAT *  pDist 
)
inlinevirtual

Definition at line 23 of file raGroupe.h.

◆ LoadInstanceData()

void raGroup::LoadInstanceData ( )
protectedvirtual

Definition at line 83 of file raGroupe.cpp.

◆ RenderMesh()

bool raGroup::RenderMesh ( LPCSTR  techniqueName = "")
virtual

Implements IRAMesh.

Definition at line 109 of file raGroupe.cpp.

◆ SetWorldMatrix() [1/2]

void raGroup::SetWorldMatrix ( const raMatrix value)
virtual

Reimplemented from raRender.

Definition at line 166 of file raGroupe.cpp.

◆ SetWorldMatrix() [2/2]

void raGroup::SetWorldMatrix ( const raMatrix value,
int  instanceNo 
)
virtual

Definition at line 173 of file raGroupe.cpp.

◆ UpdateInstanceMatrices()

void raGroup::UpdateInstanceMatrices ( )
protected

Definition at line 182 of file raGroupe.cpp.

Member Data Documentation

◆ m_InstanceMatrices

raMatrix raGroup::m_InstanceMatrices[MAX_INSTANCES]
protected

Definition at line 44 of file raGroupe.h.

◆ m_iNumInstances

int raGroup::m_iNumInstances
protected

Definition at line 45 of file raGroupe.h.

◆ m_iNumInstancesToDraw

int raGroup::m_iNumInstancesToDraw
protected

Definition at line 46 of file raGroupe.h.

◆ m_pInstanceData

ID3D11Buffer* raGroup::m_pInstanceData
protected

Definition at line 49 of file raGroupe.h.

◆ m_pInstanceList

raMatrix* raGroup::m_pInstanceList
protected

Definition at line 47 of file raGroupe.h.

◆ m_pVisual

IRAMesh* raGroup::m_pVisual
protected

Definition at line 43 of file raGroupe.h.


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