|
"L. Spiro Engine"
|
Base class for materials found in models. More...
#include <LSDMaterial.h>
Classes | |
| struct | LSD_COLOR |
Public Types | |
| enum | LSD_MATERIAL_TYPE { LSD_MT_LAMBERT, LSD_MT_PHONG } |
| typedef struct lsd::CMaterial::LSD_COLOR * | LPLSD_COLOR |
|
typedef struct lsd::CMaterial::LSD_COLOR | LPCLSD_COLOR |
Public Member Functions | |
| CMaterial &LSE_CALL | operator= (const CMaterial &_mOther) |
| virtual CMaterial &LSE_CALL | Copy (const CMaterial &_mOther) |
| virtual LSD_MATERIAL_TYPE LSE_CALL | GetType () const =0 |
| virtual LSSTD_ERRORS LSE_CALL | LoadFromStream (const lsstd::IStream &_sStream, CAllocator *_paAllocator, LSUINT32 _ui32Version)=0 |
| virtual LSVOID LSE_CALL | SetAllocator (CAllocator *_paAllocator) |
| virtual LSVOID LSE_CALL | Trash () |
| LSE_INLINE const CString &LSE_CALL | GetName () const |
| LSE_INLINE CVector4 LSE_CALL | GetDiffuseColor () const |
| LSE_INLINE const CString &LSE_CALL | GetDiffuseTexture () const |
| LSE_INLINE CVector4 LSE_CALL | GetAmbientColor () const |
| LSE_INLINE CVector4 LSE_CALL | GetEmissiveColor () const |
| LSE_INLINE CVector4 LSE_CALL | GetTransparencyColor () const |
| LSE_INLINE const CString &LSE_CALL | GetTransparencyTexture () const |
| LSE_INLINE const CString &LSE_CALL | GetNormalTexture () const |
| LSE_INLINE const CString &LSE_CALL | GetBumpTexture () const |
Protected Attributes | |
| CString | m_sName |
| CString | m_sNormalMap |
| LSD_COLOR | m_cDiffuse |
| LSD_COLOR | m_cAmbient |
| LSD_COLOR | m_cEmissive |
| LSD_COLOR | m_cBump |
| LSD_COLOR | m_cTransparent |
| LSD_COLOR | m_cDisplacement |
Base class for materials found in models.
Class CMaterial Description: Base class for materials found in models. Phong and Lambert derive from this.
| typedef struct lsd::CMaterial::LSD_COLOR * lsd::CMaterial::LPLSD_COLOR |
A color. A color is both an RGB value but may also contain a texture.
Material types.
Copy this object from another.
| _mOther | The object to copy. |
| LSE_INLINE CVector4 LSE_CALL lsd::CMaterial::GetAmbientColor | ( | ) | const |
Get the ambient color for this material.
| LSE_INLINE const CString &LSE_CALL lsd::CMaterial::GetBumpTexture | ( | ) | const |
Get the bump-map texture for this material.
| LSE_INLINE CVector4 LSE_CALL lsd::CMaterial::GetDiffuseColor | ( | ) | const |
Get the diffuse color for this material.
| LSE_INLINE const CString &LSE_CALL lsd::CMaterial::GetDiffuseTexture | ( | ) | const |
Get the diffuse texture for this material.
| LSE_INLINE CVector4 LSE_CALL lsd::CMaterial::GetEmissiveColor | ( | ) | const |
Get the emissive color for this material.
| LSE_INLINE const CString &LSE_CALL lsd::CMaterial::GetName | ( | ) | const |
Get the name of this material.
| LSE_INLINE const CString &LSE_CALL lsd::CMaterial::GetNormalTexture | ( | ) | const |
Get the normal-map texture for this material.
| LSE_INLINE CVector4 LSE_CALL lsd::CMaterial::GetTransparencyColor | ( | ) | const |
Get the transparency color for this material.
| LSE_INLINE const CString &LSE_CALL lsd::CMaterial::GetTransparencyTexture | ( | ) | const |
Get the transparency texture for this material.
| virtual LSD_MATERIAL_TYPE LSE_CALL lsd::CMaterial::GetType | ( | ) | const [pure virtual] |
Get the material type.
Implemented in lsd::CLambertMaterial.
| virtual LSSTD_ERRORS LSE_CALL lsd::CMaterial::LoadFromStream | ( | const lsstd::IStream & | _sStream, |
| CAllocator * | _paAllocator, | ||
| LSUINT32 | _ui32Version | ||
| ) | [pure virtual] |
Load material data from a stream.
| _sStream | The stream from which to load material data. |
| _paAllocator | The allocator to use for all data allocated by this object. |
| _ui32Version | File version. |
Implemented in lsd::CLambertMaterial.
Copy operator.
| _mOther | The object to copy. |
| virtual LSVOID LSE_CALL lsd::CMaterial::SetAllocator | ( | CAllocator * | _paAllocator | ) | [virtual] |
Set the allocator for this object. Can be done only once.
| _paAllocator | The allocator to use for all data allocated by this object. |
| virtual LSVOID LSE_CALL lsd::CMaterial::Trash | ( | ) | [virtual] |
Trash all contents of this material.
LSD_COLOR lsd::CMaterial::m_cAmbient [protected] |
Ambient color.
LSD_COLOR lsd::CMaterial::m_cBump [protected] |
Bump-map color.
LSD_COLOR lsd::CMaterial::m_cDiffuse [protected] |
Diffuse color.
LSD_COLOR lsd::CMaterial::m_cDisplacement [protected] |
Displacement color.
LSD_COLOR lsd::CMaterial::m_cEmissive [protected] |
Emissive color.
LSD_COLOR lsd::CMaterial::m_cTransparent [protected] |
Transparency color.
CString lsd::CMaterial::m_sName [protected] |
Name.
CString lsd::CMaterial::m_sNormalMap [protected] |
Normal map file.
1.7.3