Neo  0.5.0
Developer Documentation
Neo::Material Class Reference

The Material class contains the implementation of a material used by 3D meshes for rendering different looking surfaces. More...

#include <Material.h>

Public Member Functions

 Material (void)
 
 Material (const Material &material)
 
 ~Material (void)
 
void setType (int type)
 Sets the type of the material. More...
 
int getType (void)
 Returns the type of the material. More...
 
void setFXRef (FXRef *FXRef)
 
void setZFXRef (FXRef *ZFXRef)
 
FXRefgetFXRef (void)
 
FXRefgetZFXRef (void)
 
void setBlendMode (BLENDING_MODES blendMode)
 Changes the current blend mode. More...
 
BLENDING_MODES getBlendMode (void)
 Returns the current blend mode. More...
 
void setOpacity (float opacity)
 Sets the opacity value. More...
 
void setShininess (float shininess)
 Sets the shininess value. More...
 
void setCustomValue (float customValue)
 Sets the custom value. More...
 
void setDiffuse (const Vector3 &diffuse)
 Sets the diffuse color. More...
 
void setSpecular (const Vector3 &specular)
 Sets the specular color. More...
 
void setEmit (const Vector3 &emit)
 Sets the emit color. More...
 
void setCustomColor (const Vector3 &customColor)
 Sets the custom color. More...
 
float getOpacity (void)
 Returns the current opacity. More...
 
float getShininess (void)
 Returns the current shininess. More...
 
float getCustomValue (void)
 Returns the current custom value. More...
 
Vector3 getEmit (void) const
 Returns the current emit color. More...
 
Vector3 getDiffuse (void) const
 Returns the current diffuse color. More...
 
Vector3 getSpecular (void) const
 Returns the current specular color. More...
 
Vector3 getCustomColor (void) const
 Returns the current custom color. More...
 
void allocTexturesPass (unsigned int size)
 Allocates enough memory for all texture passes. More...
 
void clearTexturesPass (void)
 Deletes all texture passes. More...
 
void addTexturePass (Texture *texture, TEX_COMBINE_MODES combineMode, unsigned int mapChannel)
 Adds a texture pass to the internal array. More...
 
unsigned int getTexturesPassNumber (void)
 Returns the number of texture passes. More...
 
TexturePassgetTexturePass (unsigned int id)
 Returns a texture pass by ID from the internal array. More...
 

Detailed Description

The Material class contains the implementation of a material used by 3D meshes for rendering different looking surfaces.

See also
Mesh

Constructor & Destructor Documentation

Neo::Material::Material ( void  )
Neo::Material::Material ( const Material material)
Neo::Material::~Material ( void  )

Member Function Documentation

void Neo::Material::addTexturePass ( Texture texture,
TEX_COMBINE_MODES  combineMode,
unsigned int  mapChannel 
)

Adds a texture pass to the internal array.

Parameters
textureThe texture to append.
combineModeThe combine mode for multi-texturing.
mapChannelThe map channel to append the texture to.
void Neo::Material::allocTexturesPass ( unsigned int  size)

Allocates enough memory for all texture passes.

Parameters
sizeThe number of texture passes to allocate.
void Neo::Material::clearTexturesPass ( void  )

Deletes all texture passes.

BLENDING_MODES Neo::Material::getBlendMode ( void  )
inline

Returns the current blend mode.

Returns
the Blend mode.
See also
BLENDING_MODES
Vector3 Neo::Material::getCustomColor ( void  ) const
inline

Returns the current custom color.

Returns
The current custom color.
float Neo::Material::getCustomValue ( void  )
inline

Returns the current custom value.

Returns
The current custom value.
Vector3 Neo::Material::getDiffuse ( void  ) const
inline

Returns the current diffuse color.

Returns
The current diffuse color.
Vector3 Neo::Material::getEmit ( void  ) const
inline

Returns the current emit color.

Returns
The current emit color.
FXRef* Neo::Material::getFXRef ( void  )
inline
float Neo::Material::getOpacity ( void  )
inline

Returns the current opacity.

Returns
The current opacity.
float Neo::Material::getShininess ( void  )
inline

Returns the current shininess.

Returns
The current shininess.
Vector3 Neo::Material::getSpecular ( void  ) const
inline

Returns the current specular color.

Returns
The current specular color.
TexturePass* Neo::Material::getTexturePass ( unsigned int  id)
inline

Returns a texture pass by ID from the internal array.

Parameters
idThe index into the array.
unsigned int Neo::Material::getTexturesPassNumber ( void  )
inline

Returns the number of texture passes.

Returns
The number of texture passes.
int Neo::Material::getType ( void  )
inline

Returns the type of the material.

Returns
The material type.
FXRef* Neo::Material::getZFXRef ( void  )
inline
void Neo::Material::setBlendMode ( BLENDING_MODES  blendMode)
inline

Changes the current blend mode.

Parameters
blendModethe blend mode.
See also
BLENDING_MODES
void Neo::Material::setCustomColor ( const Vector3 customColor)
inline

Sets the custom color.

The color is given as RGB between 0.0f and 1.0f.

Parameters
customColorThe color.
void Neo::Material::setCustomValue ( float  customValue)
inline

Sets the custom value.

Parameters
customValueThe new value.
void Neo::Material::setDiffuse ( const Vector3 diffuse)
inline

Sets the diffuse color.

The color is given as RGB between 0.0f and 1.0f.

Parameters
diffuseThe color.
void Neo::Material::setEmit ( const Vector3 emit)
inline

Sets the emit color.

The color is given as RGB between 0.0f and 1.0f.

Parameters
emitThe color.
void Neo::Material::setFXRef ( FXRef FXRef)
inline
void Neo::Material::setOpacity ( float  opacity)
inline

Sets the opacity value.

An opacity value of 1.0f means fully opaque, 0.0 means fully transparent.

Parameters
opacityThe opacity value.
void Neo::Material::setShininess ( float  shininess)
inline

Sets the shininess value.

A higher shininess value gives smaller and brighter highlights.

Parameters
shininessThe shininess value.
void Neo::Material::setSpecular ( const Vector3 specular)
inline

Sets the specular color.

The color is given as RGB between 0.0f and 1.0f.

Parameters
specularThe color.
void Neo::Material::setType ( int  type)
inline

Sets the type of the material.

Parameters
typeThe type value.
void Neo::Material::setZFXRef ( FXRef ZFXRef)
inline

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