#include <meshmatdesc.h>
Inherits W3DMPO.
Public Types | |
| enum | { MAX_PASSES = 4 , MAX_TEX_STAGES = 2 , MAX_COLOR_ARRAYS = 2 , MAX_UV_ARRAYS = MAX_PASSES * MAX_TEX_STAGES } |
Public Member Functions | |
| MeshMatDescClass (void) | |
| MeshMatDescClass (const MeshMatDescClass &that) | |
| ~MeshMatDescClass (void) | |
| void | Reset (int polycount, int vertcount, int passcount) |
| MeshMatDescClass & | operator= (const MeshMatDescClass &that) |
| void | Init_Alternate (MeshMatDescClass &def_mat_desc, MeshMatDescClass &alternate_desc) |
| bool | Is_Empty (void) |
| void | Set_Pass_Count (int passes) |
| int | Get_Pass_Count (void) const |
| void | Set_Vertex_Count (int vertcount) |
| int | Get_Vertex_Count (void) const |
| void | Set_Polygon_Count (int polycount) |
| int | Get_Polygon_Count (void) const |
| Vector2 * | Get_UV_Array (int pass, int stage) |
| void | Install_UV_Array (int pass, int stage, Vector2 *uvs, int count) |
| void | Set_UV_Source (int pass, int stage, int sourceindex) |
| int | Get_UV_Source (int pass, int stage) |
| int | Get_UV_Array_Count (void) |
| Vector2 * | Get_UV_Array_By_Index (int index, bool create=true) |
| unsigned * | Get_DCG_Array (int pass) |
| unsigned * | Get_DIG_Array (int pass) |
| void | Set_DCG_Source (int pass, VertexMaterialClass::ColorSourceType source) |
| void | Set_DIG_Source (int pass, VertexMaterialClass::ColorSourceType source) |
| VertexMaterialClass::ColorSourceType | Get_DCG_Source (int pass) |
| VertexMaterialClass::ColorSourceType | Get_DIG_Source (int pass) |
| unsigned * | Get_Color_Array (int array, bool create=true) |
| void | Set_Single_Material (VertexMaterialClass *vmat, int pass=0) |
| void | Set_Single_Texture (TextureClass *tex, int pass=0, int stage=0) |
| void | Set_Single_Shader (ShaderClass shader, int pass=0) |
| VertexMaterialClass * | Get_Single_Material (int pass=0) const |
| TextureClass * | Get_Single_Texture (int pass=0, int stage=0) const |
| ShaderClass | Get_Single_Shader (int pass=0) const |
| VertexMaterialClass * | Peek_Single_Material (int pass=0) const |
| TextureClass * | Peek_Single_Texture (int pass=0, int stage=0) const |
| void | Set_Material (int vidx, VertexMaterialClass *vmat, int pass=0) |
| void | Set_Shader (int pidx, ShaderClass shader, int pass=0) |
| void | Set_Texture (int pidx, TextureClass *tex, int pass=0, int stage=0) |
| bool | Has_Material_Array (int pass) const |
| bool | Has_Shader_Array (int pass) const |
| bool | Has_Texture_Array (int pass, int stage) const |
| bool | Has_UV (int pass, int stage) |
| bool | Has_Color_Array (int array) |
| bool | Has_Texture_Data (int pass, int stage) |
| bool | Has_Shader_Data (int pass) |
| bool | Has_Material_Data (int pass) |
| VertexMaterialClass * | Get_Material (int vidx, int pass=0) const |
| TextureClass * | Get_Texture (int pidx, int pass=0, int stage=0) const |
| ShaderClass | Get_Shader (int pidx, int pass=0) const |
| VertexMaterialClass * | Peek_Material (int vidx, int pass=0) const |
| TextureClass * | Peek_Texture (int pidx, int pass=0, int stage=0) const |
| TexBufferClass * | Get_Texture_Array (int pass, int stage, bool create=true) |
| MatBufferClass * | Get_Material_Array (int pass, bool create=true) |
| ShaderClass * | Get_Shader_Array (int pass, bool create=true) |
| void | Make_UV_Array_Unique (int pass, int stage) |
| void | Make_Color_Array_Unique (int index) |
| void | Post_Load_Process (bool enable_lighting=true, MeshModelClass *parent=NULL) |
| void | Disable_Lighting (void) |
| bool | Do_Mappers_Need_Normals (void) |
Public Member Functions inherited from W3DMPO | |
| virtual | ~W3DMPO () |
Static Public Attributes | |
| static ShaderClass | NullShader |
Protected Member Functions | |
| void | Configure_Material (VertexMaterialClass *mtl, int pass, bool lighting_enabled) |
| void | Disable_Backface_Culling (void) |
| void | Delete_Pass (int pass) |
Protected Member Functions inherited from W3DMPO | |
| virtual int | glueEnforcer () const =0 |
Protected Attributes | |
| int | PassCount |
| int | VertexCount |
| int | PolyCount |
| UVBufferClass * | UV [MAX_UV_ARRAYS] |
| int | UVSource [MAX_PASSES][MAX_TEX_STAGES] |
| ShareBufferClass< unsigned > * | ColorArray [2] |
| VertexMaterialClass::ColorSourceType | DCGSource [MAX_PASSES] |
| VertexMaterialClass::ColorSourceType | DIGSource [MAX_PASSES] |
| TextureClass * | Texture [MAX_PASSES][MAX_TEX_STAGES] |
| ShaderClass | Shader [MAX_PASSES] |
| VertexMaterialClass * | Material [MAX_PASSES] |
| TexBufferClass * | TextureArray [MAX_PASSES][MAX_TEX_STAGES] |
| MatBufferClass * | MaterialArray [MAX_PASSES] |
| ShareBufferClass< ShaderClass > * | ShaderArray [MAX_PASSES] |
Friends | |
| class | MeshModelClass |
MeshMatDescClass - This class encapsulates all of the material description data for a mesh. WARNING: The vertex count and polygon count MUST be kept in sync with the mesh
Definition at line 61 of file meshmatdesc.h.
| anonymous enum |
| Enumerator | |
|---|---|
| MAX_PASSES | |
| MAX_TEX_STAGES | |
| MAX_COLOR_ARRAYS | |
| MAX_UV_ARRAYS | |
Definition at line 66 of file meshmatdesc.h.
| MeshMatDescClass::MeshMatDescClass | ( | void | ) |
Definition at line 178 of file meshmatdesc.cpp.
| MeshMatDescClass::MeshMatDescClass | ( | const MeshMatDescClass & | that | ) |
Definition at line 207 of file meshmatdesc.cpp.
| MeshMatDescClass::~MeshMatDescClass | ( | void | ) |
Definition at line 295 of file meshmatdesc.cpp.
|
protected |
Definition at line 941 of file meshmatdesc.cpp.
|
protected |
|
inlineprotected |
Definition at line 482 of file meshmatdesc.h.
| void MeshMatDescClass::Disable_Lighting | ( | void | ) |
| bool MeshMatDescClass::Do_Mappers_Need_Normals | ( | void | ) |
Definition at line 957 of file meshmatdesc.cpp.
Definition at line 433 of file meshmatdesc.h.
|
inline |
Definition at line 355 of file meshmatdesc.h.
|
inline |
Definition at line 423 of file meshmatdesc.h.
|
inline |
Definition at line 384 of file meshmatdesc.h.
|
inline |
Definition at line 428 of file meshmatdesc.h.
| VertexMaterialClass * MeshMatDescClass::Get_Material | ( | int | vidx, |
| int | pass = 0 ) const |
Definition at line 497 of file meshmatdesc.cpp.
| MatBufferClass * MeshMatDescClass::Get_Material_Array | ( | int | pass, |
| bool | create = true ) |
Definition at line 559 of file meshmatdesc.cpp.
|
inline |
Definition at line 91 of file meshmatdesc.h.
|
inline |
Definition at line 95 of file meshmatdesc.h.
| ShaderClass MeshMatDescClass::Get_Shader | ( | int | pidx, |
| int | pass = 0 ) const |
Definition at line 512 of file meshmatdesc.cpp.
| ShaderClass * MeshMatDescClass::Get_Shader_Array | ( | int | pass, |
| bool | create = true ) |
Definition at line 567 of file meshmatdesc.cpp.
|
inline |
Definition at line 444 of file meshmatdesc.h.
|
inline |
Definition at line 462 of file meshmatdesc.h.
| TextureClass * MeshMatDescClass::Get_Single_Texture | ( | int | pass = 0, |
| int | stage = 0 ) const |
Definition at line 300 of file meshmatdesc.cpp.
| TextureClass * MeshMatDescClass::Get_Texture | ( | int | pidx, |
| int | pass = 0, | ||
| int | stage = 0 ) const |
Definition at line 520 of file meshmatdesc.cpp.
| TexBufferClass * MeshMatDescClass::Get_Texture_Array | ( | int | pass, |
| int | stage, | ||
| bool | create = true ) |
Definition at line 551 of file meshmatdesc.cpp.
|
inline |
Definition at line 304 of file meshmatdesc.h.
Definition at line 342 of file meshmatdesc.h.
|
inline |
Definition at line 333 of file meshmatdesc.h.
|
inline |
Definition at line 324 of file meshmatdesc.h.
|
inline |
Definition at line 93 of file meshmatdesc.h.
|
inline |
Definition at line 149 of file meshmatdesc.h.
|
inline |
Definition at line 467 of file meshmatdesc.h.
|
inline |
Definition at line 153 of file meshmatdesc.h.
|
inline |
Definition at line 472 of file meshmatdesc.h.
|
inline |
Definition at line 152 of file meshmatdesc.h.
|
inline |
Definition at line 477 of file meshmatdesc.h.
|
inline |
Definition at line 151 of file meshmatdesc.h.
|
inline |
Definition at line 148 of file meshmatdesc.h.
| void MeshMatDescClass::Init_Alternate | ( | MeshMatDescClass & | def_mat_desc, |
| MeshMatDescClass & | alternate_desc ) |
Definition at line 340 of file meshmatdesc.cpp.
| void MeshMatDescClass::Install_UV_Array | ( | int | pass, |
| int | stage, | ||
| Vector2 * | uvs, | ||
| int | count ) |
Definition at line 598 of file meshmatdesc.cpp.
| bool MeshMatDescClass::Is_Empty | ( | void | ) |
Definition at line 439 of file meshmatdesc.cpp.
| void MeshMatDescClass::Make_Color_Array_Unique | ( | int | index | ) |
Definition at line 589 of file meshmatdesc.cpp.
| void MeshMatDescClass::Make_UV_Array_Unique | ( | int | pass, |
| int | stage ) |
Definition at line 579 of file meshmatdesc.cpp.
| MeshMatDescClass & MeshMatDescClass::operator= | ( | const MeshMatDescClass & | that | ) |
Definition at line 243 of file meshmatdesc.cpp.
| VertexMaterialClass * MeshMatDescClass::Peek_Material | ( | int | vidx, |
| int | pass = 0 ) const |
Definition at line 535 of file meshmatdesc.cpp.
|
inline |
Definition at line 452 of file meshmatdesc.h.
|
inline |
Definition at line 457 of file meshmatdesc.h.
| TextureClass * MeshMatDescClass::Peek_Texture | ( | int | pidx, |
| int | pass = 0, | ||
| int | stage = 0 ) const |
Definition at line 543 of file meshmatdesc.cpp.
| void MeshMatDescClass::Post_Load_Process | ( | bool | enable_lighting = true, |
| MeshModelClass * | parent = NULL ) |
Definition at line 643 of file meshmatdesc.cpp.
| void MeshMatDescClass::Reset | ( | int | polycount, |
| int | vertcount, | ||
| int | passcount ) |
Definition at line 308 of file meshmatdesc.cpp.
|
inline |
Definition at line 413 of file meshmatdesc.h.
|
inline |
Definition at line 418 of file meshmatdesc.h.
| void MeshMatDescClass::Set_Material | ( | int | vidx, |
| VertexMaterialClass * | vmat, | ||
| int | pass = 0 ) |
Definition at line 479 of file meshmatdesc.cpp.
|
inline |
Definition at line 90 of file meshmatdesc.h.
|
inline |
Definition at line 94 of file meshmatdesc.h.
| void MeshMatDescClass::Set_Shader | ( | int | pidx, |
| ShaderClass | shader, | ||
| int | pass = 0 ) |
Definition at line 485 of file meshmatdesc.cpp.
| void MeshMatDescClass::Set_Single_Material | ( | VertexMaterialClass * | vmat, |
| int | pass = 0 ) |
Definition at line 464 of file meshmatdesc.cpp.
| void MeshMatDescClass::Set_Single_Shader | ( | ShaderClass | shader, |
| int | pass = 0 ) |
Definition at line 474 of file meshmatdesc.cpp.
| void MeshMatDescClass::Set_Single_Texture | ( | TextureClass * | tex, |
| int | pass = 0, | ||
| int | stage = 0 ) |
Definition at line 469 of file meshmatdesc.cpp.
| void MeshMatDescClass::Set_Texture | ( | int | pidx, |
| TextureClass * | tex, | ||
| int | pass = 0, | ||
| int | stage = 0 ) |
Definition at line 491 of file meshmatdesc.cpp.
|
inline |
Definition at line 315 of file meshmatdesc.h.
|
inline |
Definition at line 92 of file meshmatdesc.h.
|
friend |
Definition at line 222 of file meshmatdesc.h.
|
protected |
Definition at line 208 of file meshmatdesc.h.
|
protected |
Definition at line 209 of file meshmatdesc.h.
|
protected |
Definition at line 210 of file meshmatdesc.h.
|
protected |
Definition at line 215 of file meshmatdesc.h.
|
protected |
Definition at line 219 of file meshmatdesc.h.
|
static |
Definition at line 190 of file meshmatdesc.h.
|
protected |
Definition at line 198 of file meshmatdesc.h.
|
protected |
Definition at line 200 of file meshmatdesc.h.
|
protected |
Definition at line 214 of file meshmatdesc.h.
|
protected |
Definition at line 220 of file meshmatdesc.h.
|
protected |
Definition at line 213 of file meshmatdesc.h.
|
protected |
Definition at line 218 of file meshmatdesc.h.
|
protected |
Definition at line 203 of file meshmatdesc.h.
|
protected |
Definition at line 204 of file meshmatdesc.h.
|
protected |
Definition at line 199 of file meshmatdesc.h.