![]() |
Public API Reference |
#include <material.h>
Inheritance diagram for csMaterial:

Public Methods | |
| csMaterial () | |
| create an empty material. More... | |
| csMaterial (iTextureWrapper *txt) | |
| create a material with only the texture given. More... | |
| virtual | ~csMaterial () |
| destroy material. More... | |
| csRGBcolor & | GetFlatColor () |
| Get the flat shading color. More... | |
| float | GetDiffuse () const |
| Get diffuse reflection constant for the material. More... | |
| void | SetDiffuse (float val) |
| Set diffuse reflection constant for the material. More... | |
| float | GetAmbient () const |
| Get ambient lighting for the material. More... | |
| void | SetAmbient (float val) |
| Set ambient lighting for the material. More... | |
| float | GetReflection () const |
| Get reflection of the material. More... | |
| void | SetReflection (float val) |
| Set reflection of the material. More... | |
| iTextureWrapper * | GetTextureWrapper () const |
| Get the texture (if none NULL is returned). More... | |
| void | SetTextureWrapper (iTextureWrapper *tex) |
| Set the texture (pass NULL to set no texture). More... | |
| void | AddTextureLayer (iTextureWrapper *txtwrap, uint mode, float uscale, float vscale, float ushift, float vshift) |
| Add a texture layer (currently only one supported). More... | |
| virtual void | SetEffect (iEffectDefinition *ed) |
| Set effect. More... | |
| virtual iEffectDefinition * | GetEffect () |
| Get effect. More... | |
| virtual iTextureHandle * | GetTexture () |
| Get texture. More... | |
| virtual int | GetTextureLayerCount () |
| Get num texture layers. More... | |
| virtual csTextureLayer * | GetTextureLayer (int idx) |
| Get a texture layer. More... | |
| virtual void | GetFlatColor (csRGBpixel &oColor, bool useTextureMean=1) |
| Get flat color. More... | |
| virtual void | SetFlatColor (const csRGBcolor &col) |
| Set the flat shading color. More... | |
| virtual void | GetReflection (float &oDiffuse, float &oAmbient, float &oReflection) |
| Get reflection values (diffuse, ambient, reflection). More... | |
| virtual void | SetReflection (float oDiffuse, float oAmbient, float oReflection) |
| Set reflection values (diffuse, ambient, reflection). More... | |
Public Attributes | |
| csMaterial::MaterialEngine | scfiMaterialEngine |
| iMaterialEngine implementation. More... | |
Definition at line 44 of file csengine/material.h.
|
|
create an empty material.
|
|
|
create a material with only the texture given.
|
|
|
destroy material.
|
|
||||||||||||||||||||||||||||
|
Add a texture layer (currently only one supported).
|
|
|
Get ambient lighting for the material.
Definition at line 97 of file csengine/material.h. |
|
|
Get diffuse reflection constant for the material.
Definition at line 92 of file csengine/material.h. |
|
|
Get effect.
Implements iMaterial. |
|
||||||||||||
|
Get flat color.
Implements iMaterial. |
|
|
Get the flat shading color.
Definition at line 89 of file csengine/material.h. |
|
||||||||||||||||
|
Get reflection values (diffuse, ambient, reflection).
Implements iMaterial. |
|
|
Get reflection of the material.
Definition at line 102 of file csengine/material.h. |
|
|
Get texture.
Implements iMaterial. |
|
|
Get a texture layer.
Implements iMaterial. |
|
|
Get num texture layers.
Implements iMaterial. |
|
|
Get the texture (if none NULL is returned).
Definition at line 107 of file csengine/material.h. |
|
|
Set ambient lighting for the material.
Definition at line 99 of file csengine/material.h. |
|
|
Set diffuse reflection constant for the material.
Definition at line 94 of file csengine/material.h. |
|
|
Set effect.
Implements iMaterial. |
|
|
Set the flat shading color.
Implements iMaterial. Definition at line 138 of file csengine/material.h. |
|
||||||||||||||||
|
Set reflection values (diffuse, ambient, reflection).
Implements iMaterial. Definition at line 143 of file csengine/material.h. |
|
|
Set reflection of the material.
Definition at line 104 of file csengine/material.h. |
|
|
Set the texture (pass NULL to set no texture).
|
|
|
iMaterialEngine implementation.
|