TDME2 1.9.121
Public Member Functions | Private Member Functions | Private Attributes | List of all members
SpecularMaterialProperties Class Referencefinal

Represents specular material properties. More...

#include <tdme/engine/model/SpecularMaterialProperties.h>

Collaboration diagram for SpecularMaterialProperties:
Collaboration graph

Public Member Functions

 SpecularMaterialProperties ()
 Public constructor. More...
 
 ~SpecularMaterialProperties ()
 Destructor. More...
 
bool hasEmbeddedTextures () const
 
void setEmbedTextures (bool embedTextures)
 Set if to embed textures. More...
 
const Color4getAmbientColor () const
 
void setAmbientColor (const Color4 &ambientColor)
 Set ambient color component. More...
 
const Color4getDiffuseColor () const
 
void setDiffuseColor (const Color4 &diffuseColor)
 Set diffuse color component. More...
 
const Color4getSpecularColor () const
 
void setSpecularColor (const Color4 &specularColor)
 Set specular color component. More...
 
const Color4getEmissionColor () const
 
void setEmissionColor (const Color4 &emissionColor)
 Set emission color component. More...
 
float getShininess () const
 
void setShininess (float shininess)
 Set up material shininess. More...
 
float getReflection () const
 
void setReflection (float reflection)
 Set up material reflection. More...
 
int32_t getTextureAtlasSize () const
 
void setTextureAtlasSize (int32_t textureAtlasSize)
 Set texture atlas size. More...
 
const string & getDiffuseTexturePathName () const
 
void setDiffuseTexturePathName (const string &diffuseTexturePathName)
 Set diffuse texture path name. More...
 
const string & getDiffuseTextureFileName () const
 
void setDiffuseTextureFileName (const string &diffuseTextureFileName)
 Set diffuse texture file name. More...
 
const string & getDiffuseTransparencyTexturePathName () const
 
const string & getDiffuseTransparencyTextureFileName () const
 
void setDiffuseTexture (Texture *diffuseTexture)
 Set up a diffuse texture by the texture itself. More...
 
void setDiffuseTexture (const string &pathName, const string &fileName, const string &transparencyPathName=string(), const string &transparencyFileName=string())
 Set up a diffuse texture. More...
 
bool hasDiffuseTexture () const
 
TexturegetDiffuseTexture () const
 
bool hasDiffuseTextureTransparency () const
 
bool hasDiffuseTextureMaskedTransparency () const
 
void setDiffuseTextureMaskedTransparency (bool maskedTransparency)
 Set if diffuse texture uses masked transparency(means pixel are eighter opaque or not visible) More...
 
float getDiffuseTextureMaskedTransparencyThreshold () const
 
void setDiffuseTextureMaskedTransparencyThreshold (float maskedTransparencyThreshold)
 Set diffuse texture masked transparency threshold. More...
 
const string & getSpecularTexturePathName () const
 
void setSpecularTexturePathName (const string &specularTexturePathName)
 Set specular texture path name. More...
 
const string & getSpecularTextureFileName () const
 
void setSpecularTextureFileName (const string &specularTextureFileName)
 Set specular texture file name. More...
 
void setSpecularTexture (Texture *specularTexture)
 Set up a specular texture by the texture itself. More...
 
void setSpecularTexture (const string &pathName, const string &fileName)
 Set up a specular texture. More...
 
bool hasSpecularTexture () const
 
TexturegetSpecularTexture () const
 
const string & getNormalTexturePathName () const
 
void setNormalTexturePathName (const string &normalTexturePathName)
 Set normal texture path name. More...
 
const string & getNormalTextureFileName () const
 
void setNormalTextureFileName (const string &normalTextureFileName)
 Set normal texture file name. More...
 
void setNormalTexture (Texture *normalTexture)
 Set up a normal texture by the texture itself. More...
 
void setNormalTexture (const string &pathName, const string &fileName)
 Set up a normal texture. More...
 
bool hasNormalTexture () const
 
TexturegetNormalTexture () const
 
bool hasColorTransparency () const
 
bool getDiffuseTextureTransparency ()
 
void setDiffuseTextureTransparency (bool textureTransparency)
 Set diffuse texture transparency. More...
 
bool hasTextureTransparency () const
 
const Matrix2D3x3getTextureMatrix () const
 
void setTextureMatrix (const Matrix2D3x3 &textureMatrix)
 Set texture matrix. More...
 

Private Member Functions

void checkDiffuseTextureTransparency ()
 Checks and set ups diffuse texture transparency. More...
 

Private Attributes

bool embedTextures
 
Color4 ambientColor
 
Color4 diffuseColor
 
Color4 specularColor
 
Color4 emissionColor
 
float shininess
 
float reflection
 
string diffuseTexturePathName
 
string diffuseTextureFileName
 
string diffuseTransparencyTexturePathName
 
string diffuseTransparencyTextureFileName
 
TexturediffuseTexture
 
bool diffuseTextureMaskedTransparency
 
float diffuseTextureMaskedTransparencyThreshold
 
bool diffuseTextureTransparency
 
string specularTexturePathName
 
string specularTextureFileName
 
TexturespecularTexture
 
string normalTexturePathName
 
string normalTextureFileName
 
TexturenormalTexture
 
Matrix2D3x3 textureMatrix
 
int textureAtlasSize
 

Detailed Description

Represents specular material properties.

Author
andreas.drewke
Version
$Id$

Definition at line 22 of file SpecularMaterialProperties.h.

Constructor & Destructor Documentation

◆ SpecularMaterialProperties()

Public constructor.

Definition at line 21 of file SpecularMaterialProperties.cpp.

◆ ~SpecularMaterialProperties()

Destructor.

Definition at line 39 of file SpecularMaterialProperties.cpp.

Member Function Documentation

◆ checkDiffuseTextureTransparency()

void checkDiffuseTextureTransparency ( )
private

Checks and set ups diffuse texture transparency.

Definition at line 87 of file SpecularMaterialProperties.cpp.

◆ getAmbientColor()

const Color4 & getAmbientColor ( ) const
inline
Returns
ambient color

Definition at line 84 of file SpecularMaterialProperties.h.

◆ getDiffuseColor()

const Color4 & getDiffuseColor ( ) const
inline
Returns
diffuse color

Definition at line 99 of file SpecularMaterialProperties.h.

◆ getDiffuseTexture()

Texture * getDiffuseTexture ( ) const
inline
Returns
the material's diffuse texture

Definition at line 255 of file SpecularMaterialProperties.h.

◆ getDiffuseTextureFileName()

const string & getDiffuseTextureFileName ( ) const
inline
Returns
diffuse texture file name

Definition at line 204 of file SpecularMaterialProperties.h.

◆ getDiffuseTextureMaskedTransparencyThreshold()

float getDiffuseTextureMaskedTransparencyThreshold ( ) const
inline
Returns
diffuse masked transparency threshold

Definition at line 284 of file SpecularMaterialProperties.h.

◆ getDiffuseTexturePathName()

const string & getDiffuseTexturePathName ( ) const
inline
Returns
diffuse texture path name

Definition at line 189 of file SpecularMaterialProperties.h.

◆ getDiffuseTextureTransparency()

bool getDiffuseTextureTransparency ( )
inline
Returns
diffuse texture has transparency

Definition at line 420 of file SpecularMaterialProperties.h.

◆ getDiffuseTransparencyTextureFileName()

const string & getDiffuseTransparencyTextureFileName ( ) const
inline
Returns
diffuse transparency texture file name

Definition at line 226 of file SpecularMaterialProperties.h.

◆ getDiffuseTransparencyTexturePathName()

const string & getDiffuseTransparencyTexturePathName ( ) const
inline
Returns
diffuse transparency texture path name

Definition at line 219 of file SpecularMaterialProperties.h.

◆ getEmissionColor()

const Color4 & getEmissionColor ( ) const
inline
Returns
emission color

Definition at line 129 of file SpecularMaterialProperties.h.

◆ getNormalTexture()

Texture * getNormalTexture ( ) const
inline
Returns
the material's normal texture

Definition at line 406 of file SpecularMaterialProperties.h.

◆ getNormalTextureFileName()

const string & getNormalTextureFileName ( ) const
inline
Returns
normal texture file name

Definition at line 371 of file SpecularMaterialProperties.h.

◆ getNormalTexturePathName()

const string & getNormalTexturePathName ( ) const
inline
Returns
normal texture path name

Definition at line 356 of file SpecularMaterialProperties.h.

◆ getReflection()

float getReflection ( ) const
inline
Returns
reflection

Definition at line 159 of file SpecularMaterialProperties.h.

◆ getShininess()

float getShininess ( ) const
inline
Returns
shininess

Definition at line 144 of file SpecularMaterialProperties.h.

◆ getSpecularColor()

const Color4 & getSpecularColor ( ) const
inline
Returns
specular color

Definition at line 114 of file SpecularMaterialProperties.h.

◆ getSpecularTexture()

Texture * getSpecularTexture ( ) const
inline
Returns
the material's specular texture

Definition at line 349 of file SpecularMaterialProperties.h.

◆ getSpecularTextureFileName()

const string & getSpecularTextureFileName ( ) const
inline
Returns
specular texture file name

Definition at line 314 of file SpecularMaterialProperties.h.

◆ getSpecularTexturePathName()

const string & getSpecularTexturePathName ( ) const
inline
Returns
specular texture path name

Definition at line 299 of file SpecularMaterialProperties.h.

◆ getTextureAtlasSize()

int32_t getTextureAtlasSize ( ) const
inline
Returns
texture atlas size

Definition at line 174 of file SpecularMaterialProperties.h.

◆ getTextureMatrix()

const Matrix2D3x3 & getTextureMatrix ( ) const
inline
Returns
texture matrix

Definition at line 442 of file SpecularMaterialProperties.h.

◆ hasColorTransparency()

bool hasColorTransparency ( ) const
inline
Returns
if color is transparent

Definition at line 413 of file SpecularMaterialProperties.h.

◆ hasDiffuseTexture()

bool hasDiffuseTexture ( ) const
inline
Returns
if material has a diffuse texture

Definition at line 248 of file SpecularMaterialProperties.h.

◆ hasDiffuseTextureMaskedTransparency()

bool hasDiffuseTextureMaskedTransparency ( ) const
inline
Returns
diffuse texture has masked transparency, means pixel are eighter opaque or not visible

Definition at line 269 of file SpecularMaterialProperties.h.

◆ hasDiffuseTextureTransparency()

bool hasDiffuseTextureTransparency ( ) const
inline
Returns
diffuse texture has transparent pixels

Definition at line 262 of file SpecularMaterialProperties.h.

◆ hasEmbeddedTextures()

bool hasEmbeddedTextures ( ) const
inline
Returns
if textures will be embedded in model files

Definition at line 69 of file SpecularMaterialProperties.h.

◆ hasNormalTexture()

bool hasNormalTexture ( ) const
inline
Returns
if material has a normal texture

Definition at line 399 of file SpecularMaterialProperties.h.

◆ hasSpecularTexture()

bool hasSpecularTexture ( ) const
inline
Returns
if material has a specular texture

Definition at line 342 of file SpecularMaterialProperties.h.

◆ hasTextureTransparency()

bool hasTextureTransparency ( ) const
inline
Returns
if texture has transparency with masked transparency disabled

Definition at line 435 of file SpecularMaterialProperties.h.

◆ setAmbientColor()

void setAmbientColor ( const Color4 ambientColor)
inline

Set ambient color component.

Parameters
ambientColorambient color

Definition at line 92 of file SpecularMaterialProperties.h.

◆ setDiffuseColor()

void setDiffuseColor ( const Color4 diffuseColor)
inline

Set diffuse color component.

Parameters
diffuseColordiffuse color

Definition at line 107 of file SpecularMaterialProperties.h.

◆ setDiffuseTexture() [1/2]

void setDiffuseTexture ( const string &  pathName,
const string &  fileName,
const string &  transparencyPathName = string(),
const string &  transparencyFileName = string() 
)

Set up a diffuse texture.

Parameters
pathNamepath name
fileNamefile name
transparencyPathNametransparency path name
transparencyFileNametransparency file name

Definition at line 56 of file SpecularMaterialProperties.cpp.

◆ setDiffuseTexture() [2/2]

void setDiffuseTexture ( Texture diffuseTexture)

Set up a diffuse texture by the texture itself.

Parameters
diffuseTexturediffuse texture

Definition at line 45 of file SpecularMaterialProperties.cpp.

◆ setDiffuseTextureFileName()

void setDiffuseTextureFileName ( const string &  diffuseTextureFileName)
inline

Set diffuse texture file name.

Returns
diffuseTextureFileName diffuse texture file name

Definition at line 212 of file SpecularMaterialProperties.h.

◆ setDiffuseTextureMaskedTransparency()

void setDiffuseTextureMaskedTransparency ( bool  maskedTransparency)
inline

Set if diffuse texture uses masked transparency(means pixel are eighter opaque or not visible)

Parameters
maskedTransparencymasked transparency

Definition at line 277 of file SpecularMaterialProperties.h.

◆ setDiffuseTextureMaskedTransparencyThreshold()

void setDiffuseTextureMaskedTransparencyThreshold ( float  maskedTransparencyThreshold)
inline

Set diffuse texture masked transparency threshold.

Parameters
maskedTransparencyThresholddiffuse texture masked transparency threshold

Definition at line 292 of file SpecularMaterialProperties.h.

◆ setDiffuseTexturePathName()

void setDiffuseTexturePathName ( const string &  diffuseTexturePathName)
inline

Set diffuse texture path name.

Parameters
diffuseTexturePathNamediffuse texture path name

Definition at line 197 of file SpecularMaterialProperties.h.

◆ setDiffuseTextureTransparency()

void setDiffuseTextureTransparency ( bool  textureTransparency)
inline

Set diffuse texture transparency.

Parameters
diffuseTextureTransparencydiffuse texture has transparency

Definition at line 428 of file SpecularMaterialProperties.h.

◆ setEmbedTextures()

void setEmbedTextures ( bool  embedTextures)
inline

Set if to embed textures.

Parameters
embedTexturesembed textures

Definition at line 77 of file SpecularMaterialProperties.h.

◆ setEmissionColor()

void setEmissionColor ( const Color4 emissionColor)
inline

Set emission color component.

Parameters
emissionColoremission color

Definition at line 137 of file SpecularMaterialProperties.h.

◆ setNormalTexture() [1/2]

void setNormalTexture ( const string &  pathName,
const string &  fileName 
)

Set up a normal texture.

Parameters
pathNamepath name
fileNamefile name

Definition at line 127 of file SpecularMaterialProperties.cpp.

◆ setNormalTexture() [2/2]

void setNormalTexture ( Texture normalTexture)

Set up a normal texture by the texture itself.

Parameters
normalTexturenormal texture

Definition at line 119 of file SpecularMaterialProperties.cpp.

◆ setNormalTextureFileName()

void setNormalTextureFileName ( const string &  normalTextureFileName)
inline

Set normal texture file name.

Returns
normalTextureFileName normal texture file name

Definition at line 379 of file SpecularMaterialProperties.h.

◆ setNormalTexturePathName()

void setNormalTexturePathName ( const string &  normalTexturePathName)
inline

Set normal texture path name.

Parameters
normalTexturePathNamenormal texture path name

Definition at line 364 of file SpecularMaterialProperties.h.

◆ setReflection()

void setReflection ( float  reflection)
inline

Set up material reflection.

Parameters
reflectionreflection

Definition at line 167 of file SpecularMaterialProperties.h.

◆ setShininess()

void setShininess ( float  shininess)
inline

Set up material shininess.

Parameters
shininessshininess

Definition at line 152 of file SpecularMaterialProperties.h.

◆ setSpecularColor()

void setSpecularColor ( const Color4 specularColor)
inline

Set specular color component.

Parameters
specularColorspecular color

Definition at line 122 of file SpecularMaterialProperties.h.

◆ setSpecularTexture() [1/2]

void setSpecularTexture ( const string &  pathName,
const string &  fileName 
)

Set up a specular texture.

Parameters
pathNamepath name
fileNamefile name

Definition at line 110 of file SpecularMaterialProperties.cpp.

◆ setSpecularTexture() [2/2]

void setSpecularTexture ( Texture specularTexture)

Set up a specular texture by the texture itself.

Parameters
specularTexturespecular texture

Definition at line 102 of file SpecularMaterialProperties.cpp.

◆ setSpecularTextureFileName()

void setSpecularTextureFileName ( const string &  specularTextureFileName)
inline

Set specular texture file name.

Returns
specularTextureFileName specular texture file name

Definition at line 322 of file SpecularMaterialProperties.h.

◆ setSpecularTexturePathName()

void setSpecularTexturePathName ( const string &  specularTexturePathName)
inline

Set specular texture path name.

Parameters
specularTexturePathNamespecular texture path name

Definition at line 307 of file SpecularMaterialProperties.h.

◆ setTextureAtlasSize()

void setTextureAtlasSize ( int32_t  textureAtlasSize)
inline

Set texture atlas size.

Parameters
textureAtlasSizetexture atlas size

Definition at line 182 of file SpecularMaterialProperties.h.

◆ setTextureMatrix()

void setTextureMatrix ( const Matrix2D3x3 textureMatrix)
inline

Set texture matrix.

Parameters
texturematrix

Definition at line 450 of file SpecularMaterialProperties.h.

Member Data Documentation

◆ ambientColor

Color4 ambientColor
private

Definition at line 27 of file SpecularMaterialProperties.h.

◆ diffuseColor

Color4 diffuseColor
private

Definition at line 28 of file SpecularMaterialProperties.h.

◆ diffuseTexture

Texture* diffuseTexture
private

Definition at line 37 of file SpecularMaterialProperties.h.

◆ diffuseTextureFileName

string diffuseTextureFileName
private

Definition at line 34 of file SpecularMaterialProperties.h.

◆ diffuseTextureMaskedTransparency

bool diffuseTextureMaskedTransparency
private

Definition at line 38 of file SpecularMaterialProperties.h.

◆ diffuseTextureMaskedTransparencyThreshold

float diffuseTextureMaskedTransparencyThreshold
private

Definition at line 39 of file SpecularMaterialProperties.h.

◆ diffuseTexturePathName

string diffuseTexturePathName
private

Definition at line 33 of file SpecularMaterialProperties.h.

◆ diffuseTextureTransparency

bool diffuseTextureTransparency
private

Definition at line 40 of file SpecularMaterialProperties.h.

◆ diffuseTransparencyTextureFileName

string diffuseTransparencyTextureFileName
private

Definition at line 36 of file SpecularMaterialProperties.h.

◆ diffuseTransparencyTexturePathName

string diffuseTransparencyTexturePathName
private

Definition at line 35 of file SpecularMaterialProperties.h.

◆ embedTextures

bool embedTextures
private

Definition at line 26 of file SpecularMaterialProperties.h.

◆ emissionColor

Color4 emissionColor
private

Definition at line 30 of file SpecularMaterialProperties.h.

◆ normalTexture

Texture* normalTexture
private

Definition at line 46 of file SpecularMaterialProperties.h.

◆ normalTextureFileName

string normalTextureFileName
private

Definition at line 45 of file SpecularMaterialProperties.h.

◆ normalTexturePathName

string normalTexturePathName
private

Definition at line 44 of file SpecularMaterialProperties.h.

◆ reflection

float reflection
private

Definition at line 32 of file SpecularMaterialProperties.h.

◆ shininess

float shininess
private

Definition at line 31 of file SpecularMaterialProperties.h.

◆ specularColor

Color4 specularColor
private

Definition at line 29 of file SpecularMaterialProperties.h.

◆ specularTexture

Texture* specularTexture
private

Definition at line 43 of file SpecularMaterialProperties.h.

◆ specularTextureFileName

string specularTextureFileName
private

Definition at line 42 of file SpecularMaterialProperties.h.

◆ specularTexturePathName

string specularTexturePathName
private

Definition at line 41 of file SpecularMaterialProperties.h.

◆ textureAtlasSize

int textureAtlasSize
private

Definition at line 48 of file SpecularMaterialProperties.h.

◆ textureMatrix

Matrix2D3x3 textureMatrix
private

Definition at line 47 of file SpecularMaterialProperties.h.


The documentation for this class was generated from the following files: