#include <matrixmapper.h>
Inherits TextureMapperClass.
Inherited by CompositeMatrixMapperClass.
Public Types | |
| enum | { INVERT_DEPTH_GRADIENT = 0x00000001 } |
| enum | MappingType { ORTHO_PROJECTION = 0 , PERSPECTIVE_PROJECTION , DEPTH_GRADIENT , NORMAL_GRADIENT } |
Public Types inherited from TextureMapperClass | |
| enum | { MAPPER_ID_UNKNOWN , MAPPER_ID_LINEAR_OFFSET , MAPPER_ID_CLASSIC_ENVIRONMENT , MAPPER_ID_ENVIRONMENT , MAPPER_ID_SCREEN , MAPPER_ID_ANIMATING_1D , MAPPER_ID_AXIAL , MAPPER_ID_SILHOUETTE , MAPPER_ID_SCALE , MAPPER_ID_GRID , MAPPER_ID_ROTATE , MAPPER_ID_SINE_LINEAR_OFFSET , MAPPER_ID_STEP_LINEAR_OFFSET , MAPPER_ID_ZIGZAG_LINEAR_OFFSET , MAPPER_ID_WS_CLASSIC_ENVIRONMENT , MAPPER_ID_WS_ENVIRONMENT , MAPPER_ID_GRID_CLASSIC_ENVIRONMENT , MAPPER_ID_GRID_ENVIRONMENT , MAPPER_ID_RANDOM , MAPPER_ID_EDGE , MAPPER_ID_BUMPENV , MAPPER_ID_GRID_WS_CLASSIC_ENVIRONMENT , MAPPER_ID_GRID_WS_ENVIRONMENT } |
Public Member Functions | |
| MatrixMapperClass (int stage) | |
| void | Set_Flag (uint32 flag, bool onoff) |
| bool | Get_Flag (uint32 flag) const |
| void | Set_Type (MappingType type) |
| MappingType | Get_Type (void) |
| void | Set_Texture_Transform (const Matrix3D &view_to_texture, float texsize) |
| void | Set_Texture_Transform (const Matrix4x4 &view_to_texture, float texsize) |
| const Matrix4x4 & | Get_Texture_Transform (void) const |
| void | Set_Gradient_U_Coord (float coord) |
| float | Get_Gradient_U_Coord (void) |
| void | Compute_Texture_Coordinate (const Vector3 &point, Vector3 *set_stq) |
| TextureMapperClass * | Clone (void) const |
| virtual void | Apply (int uv_array_index) |
| virtual void | Calculate_Texture_Matrix (Matrix4x4 &tex_matrix) |
Public Member Functions inherited from TextureMapperClass | |
| TextureMapperClass (unsigned int stage=0) | |
| TextureMapperClass (const TextureMapperClass &src) | |
| virtual | ~TextureMapperClass (void) |
| virtual int | Mapper_ID (void) const |
| virtual bool | Is_Time_Variant (void) |
| virtual void | Reset (void) |
| virtual bool | Needs_Normals (void) |
| void | Set_Stage (int stage) |
| int | Get_Stage (void) const |
Public Member Functions inherited from W3DMPO | |
| virtual | ~W3DMPO () |
Public Member Functions inherited from RefCountClass | |
| RefCountClass (void) | |
| RefCountClass (const RefCountClass &) | |
| void | Add_Ref (void) const |
| WWINLINE void | Release_Ref (void) const |
| int | Num_Refs (void) const |
| virtual void | Delete_This (void) |
Protected Member Functions | |
| void | Update_View_To_Pixel_Transform (float texsize) |
Protected Member Functions inherited from W3DMPO | |
| virtual int | glueEnforcer () const =0 |
Protected Member Functions inherited from RefCountClass | |
| virtual | ~RefCountClass (void) |
Protected Attributes | |
| uint32 | Flags |
| MappingType | Type |
| Matrix4x4 | ViewToTexture |
| Matrix4x4 | ViewToPixel |
| Vector3 | ViewSpaceProjectionNormal |
| float | GradientUCoord |
Protected Attributes inherited from TextureMapperClass | |
| unsigned int | Stage |
Additional Inherited Members | |
Static Public Member Functions inherited from RefCountClass | |
| static int | Total_Refs (void) |
| static RefCountClass * | Add_Active_Ref (RefCountClass *obj) |
| static RefCountClass * | Set_Ref_Owner (RefCountClass *obj, char *file, int line) |
| static void | Remove_Active_Ref (RefCountClass *obj) |
| static bool | Validate_Active_Ref (RefCountClass *obj) |
Public Attributes inherited from RefCountClass | |
| RefCountNodeClass | ActiveRefNode |
| ActiveRefStruct | ActiveRefInfo |
Static Public Attributes inherited from RefCountClass | |
| static RefCountListClass | ActiveRefList |
MatrixMapperClass. Does the chore of computing the u-v coorinates for a projected texture. Note that this VP must be "baby-sat" by something external to ensure that its ViewToTexture transform is up-to-date. I use it in the TexProjectClass to implement projected textures.
NOTE: for projected textures, the equation for computing a valid ViewToTexture transform is as follows (assuming my usual column vectors, etc): -1 ViewToTexture = Projection * Mwrld-shadow * Mwrld-camera
Definition at line 63 of file matrixmapper.h.
| anonymous enum |
| Enumerator | |
|---|---|
| INVERT_DEPTH_GRADIENT | |
Definition at line 68 of file matrixmapper.h.
| Enumerator | |
|---|---|
| ORTHO_PROJECTION | |
| PERSPECTIVE_PROJECTION | |
| DEPTH_GRADIENT | |
| NORMAL_GRADIENT | |
Definition at line 72 of file matrixmapper.h.
| MatrixMapperClass::MatrixMapperClass | ( | int | stage | ) |
Definition at line 71 of file matrixmapper.cpp.
|
virtual |
Implements TextureMapperClass.
Reimplemented in CompositeMatrixMapperClass.
Definition at line 226 of file matrixmapper.cpp.
|
virtual |
Implements TextureMapperClass.
Reimplemented in CompositeMatrixMapperClass.
Definition at line 294 of file matrixmapper.cpp.
|
inlinevirtual |
Implements TextureMapperClass.
Definition at line 99 of file matrixmapper.h.
Definition at line 207 of file matrixmapper.cpp.
Definition at line 152 of file matrixmapper.h.
|
inline |
Definition at line 95 of file matrixmapper.h.
|
inline |
Definition at line 167 of file matrixmapper.h.
|
inline |
Definition at line 162 of file matrixmapper.h.
Definition at line 143 of file matrixmapper.h.
|
inline |
Definition at line 94 of file matrixmapper.h.
| void MatrixMapperClass::Set_Texture_Transform | ( | const Matrix3D & | view_to_texture, |
| float | texsize ) |
Definition at line 94 of file matrixmapper.cpp.
| void MatrixMapperClass::Set_Texture_Transform | ( | const Matrix4x4 & | view_to_texture, |
| float | texsize ) |
Definition at line 112 of file matrixmapper.cpp.
|
inline |
Definition at line 157 of file matrixmapper.h.
|
protected |
Definition at line 131 of file matrixmapper.cpp.
|
protected |
Definition at line 108 of file matrixmapper.h.
|
protected |
Definition at line 113 of file matrixmapper.h.
|
protected |
Definition at line 109 of file matrixmapper.h.
|
protected |
Definition at line 112 of file matrixmapper.h.
|
protected |
Definition at line 111 of file matrixmapper.h.
|
protected |
Definition at line 110 of file matrixmapper.h.