TSMaterialList Class Reference#include <tsShape.h>
Inheritance diagram for TSMaterialList:
[legend]
Detailed Description
Specialized material list for 3space objects.
- Note:
- Reflectance amounts on 3space objects are determined by the alpha channel of the base material texture
|
Public Types |
| enum | {
S_Wrap = BIT(0),
T_Wrap = BIT(1),
Translucent = BIT(2),
Additive = BIT(3),
Subtractive = BIT(4),
SelfIlluminating = BIT(5),
NeverEnvMap = BIT(6),
NoMipMap = BIT(7),
MipMap_ZeroBorder = BIT(8),
IflMaterial = BIT(27),
IflFrame = BIT(28),
DetailMapOnly = BIT(29),
BumpMapOnly = BIT(30),
ReflectanceMapOnly = BIT(31),
AuxiliaryMap = DetailMapOnly | BumpMapOnly | ReflectanceMapOnly
} |
Public Member Functions |
| | TSMaterialList (U32 materialCount, const char **materialNames, const U32 *materialFlags, const U32 *reflectanceMaps, const U32 *bumpMaps, const U32 *detailMaps, const F32 *detailScales, const F32 *reflectionAmounts) |
| | TSMaterialList (U32 materialCount, const char **materialNames, const U32 *materialFlags, const U32 *reflectanceMaps, const U32 *bumpMaps, const U32 *detailMaps, const U32 *lightMaps, const F32 *detailScales, const F32 *reflectionAmounts) |
| | TSMaterialList () |
| | TSMaterialList (const TSMaterialList *) |
| | ~TSMaterialList () |
| void | free () |
| void | load (U32 index, const char *path=0) |
| bool | load (TextureHandleType type, const char *path=0, bool clampToEdge=false) |
| U32 | getFlags (U32 index) |
| void | setFlags (U32 index, U32 value) |
| void | remap (U32 toIndex, U32 fromIndex) |
| | support for ifl sequences
|
| void | push_back (const char *name, U32 flags, U32 a=0xFFFFFFFF, U32 b=0xFFFFFFFF, U32 c=0xFFFFFFFF, F32 dm=1.0f, F32 em=1.0f, U32 l=0xFFFFFFFF) |
| | pre-load only ... support for ifl sequences
|
|
| TextureHandle * | getReflectionMap (U32 index) |
| F32 | getReflectionAmount (U32 index) |
| TextureHandle * | getBumpMap (U32 index) |
| TextureHandle * | getDetailMap (U32 index) |
| TextureHandle * | getLightMap (U32 index) |
| F32 | getDetailMapScale (U32 index) |
| bool | reflectionInAlpha (U32 index) |
|
Functions for reading/writing to/from streams
|
| bool | write (Stream &) |
| bool | read (Stream &) |
Private Types |
| typedef MaterialList | Parent |
Private Member Functions |
| void | allocate (U32 sz) |
Private Attributes |
| Vector< U32 > | mFlags |
| Vector< U32 > | mReflectanceMaps |
| Vector< U32 > | mBumpMaps |
| Vector< U32 > | mDetailMaps |
| Vector< U32 > | mLightMaps |
| Vector< F32 > | mDetailScales |
| Vector< F32 > | mReflectionAmounts |
| bool | mNamesTransformed |
Member Typedef Documentation
Member Enumeration Documentation
- Enumerator:
-
| S_Wrap |
|
| T_Wrap |
|
| Translucent |
|
| Additive |
|
| Subtractive |
|
| SelfIlluminating |
|
| NeverEnvMap |
|
| NoMipMap |
|
| MipMap_ZeroBorder |
|
| IflMaterial |
|
| IflFrame |
|
| DetailMapOnly |
|
| BumpMapOnly |
|
| ReflectanceMapOnly |
|
| AuxiliaryMap |
|
Constructor & Destructor Documentation
| TSMaterialList::TSMaterialList |
( |
U32 |
materialCount, |
|
|
const char ** |
materialNames, |
|
|
const U32 * |
materialFlags, |
|
|
const U32 * |
reflectanceMaps, |
|
|
const U32 * |
bumpMaps, |
|
|
const U32 * |
detailMaps, |
|
|
const F32 * |
detailScales, |
|
|
const F32 * |
reflectionAmounts | |
|
) |
| | |
| TSMaterialList::TSMaterialList |
( |
U32 |
materialCount, |
|
|
const char ** |
materialNames, |
|
|
const U32 * |
materialFlags, |
|
|
const U32 * |
reflectanceMaps, |
|
|
const U32 * |
bumpMaps, |
|
|
const U32 * |
detailMaps, |
|
|
const U32 * |
lightMaps, |
|
|
const F32 * |
detailScales, |
|
|
const F32 * |
reflectionAmounts | |
|
) |
| | |
| TSMaterialList::TSMaterialList |
( |
|
) |
|
| TSMaterialList::~TSMaterialList |
( |
|
) |
|
Member Function Documentation
| void TSMaterialList::allocate |
( |
U32 |
sz |
) |
[private] |
| void TSMaterialList::free |
( |
|
) |
[virtual] |
| void TSMaterialList::load |
( |
U32 |
index, |
|
|
const char * |
path = 0 | |
|
) |
| | [virtual] |
| bool TSMaterialList::load |
( |
TextureHandleType |
type, |
|
|
const char * |
path = 0, |
|
|
bool |
clampToEdge = false | |
|
) |
| | [inline] |
| TextureHandle* TSMaterialList::getReflectionMap |
( |
U32 |
index |
) |
[inline] |
| F32 TSMaterialList::getReflectionAmount |
( |
U32 |
index |
) |
[inline] |
| TextureHandle* TSMaterialList::getBumpMap |
( |
U32 |
index |
) |
[inline] |
| TextureHandle* TSMaterialList::getDetailMap |
( |
U32 |
index |
) |
[inline] |
| TextureHandle* TSMaterialList::getLightMap |
( |
U32 |
index |
) |
[inline] |
| F32 TSMaterialList::getDetailMapScale |
( |
U32 |
index |
) |
[inline] |
| bool TSMaterialList::reflectionInAlpha |
( |
U32 |
index |
) |
[inline] |
| U32 TSMaterialList::getFlags |
( |
U32 |
index |
) |
|
| void TSMaterialList::setFlags |
( |
U32 |
index, |
|
|
U32 |
value | |
|
) |
| | |
| void TSMaterialList::remap |
( |
U32 |
toIndex, |
|
|
U32 |
fromIndex | |
|
) |
| | |
support for ifl sequences
| void TSMaterialList::push_back |
( |
const char * |
name, |
|
|
U32 |
flags, |
|
|
U32 |
a = 0xFFFFFFFF, |
|
|
U32 |
b = 0xFFFFFFFF, |
|
|
U32 |
c = 0xFFFFFFFF, |
|
|
F32 |
dm = 1.0f, |
|
|
F32 |
em = 1.0f, |
|
|
U32 |
l = 0xFFFFFFFF | |
|
) |
| | |
pre-load only ... support for ifl sequences
| bool TSMaterialList::write |
( |
Stream & |
|
) |
|
| bool TSMaterialList::read |
( |
Stream & |
|
) |
|
Field Documentation
|