Python Script Engine  7.0
GL Studio Editor Python Script API
Material Class Reference

Public Types

enum  ColorMaterialMode_e {
  NO_COLOR_MATERIAL,
  DIFFUSE_COLOR_MATERIAL,
  AMBIENT_COLOR_MATERIAL,
  DIFFUSE_AND_AMBIENT_COLOR_MATERIAL,
  EMISSION_COLOR_MATERIAL,
  SPECULAR_COLOR_MATERIAL
}
 

Public Member Functions

 Material ()
 
 Material (Material &src)
 
 Material (String name, GlsColor ambient, GlsColor diffuse, GlsColor specular, GlsColor emission, float shininess, bool inUse, ColorMaterialMode_e mode)
 
String GetName ()
 
void SetName (String name)
 
GlsColor GetAmbient ()
 
void SetAmbient (GlsColor ambient)
 
GlsColor GetDiffuse ()
 
void SetDiffuse (GlsColor diffuse)
 
GlsColor GetSpecular ()
 
void SetSpecular (GlsColor specular)
 
GlsColor GetEmission ()
 
void SetEmission (GlsColor emission)
 
float GetShininess ()
 
void SetShininess (float shininess)
 
ColorMaterialMode_e GetColorMaterialMode ()
 
void SetColorMaterialMode (ColorMaterialMode_e mode)
 

Detailed Description

common editor interface material

Member Enumeration Documentation

Enumerator
NO_COLOR_MATERIAL 

glColorMaterial will be disabled for the object

DIFFUSE_COLOR_MATERIAL 

glColorMaterial will be enabled for the diffuse material

AMBIENT_COLOR_MATERIAL 

glColorMaterial will be enabled for the ambient material

DIFFUSE_AND_AMBIENT_COLOR_MATERIAL 

glColorMaterial will be enabled for the diffuse & ambient materials

EMISSION_COLOR_MATERIAL 

glColorMaterial will be enabled for the emission material

SPECULAR_COLOR_MATERIAL 

glColorMaterial will be enabled for the specular material

Constructor & Destructor Documentation

Material::Material ( )

Default Constructor.

Material::Material ( Material src)

Copy Constructor.

Parameters
srcmaterial wrapper to copy
Material::Material ( String  name,
GlsColor  ambient,
GlsColor  diffuse,
GlsColor  specular,
GlsColor  emission,
float  shininess,
bool  inUse,
ColorMaterialMode_e  mode 
)

Creates a material with the given information set.

Parameters
namename of new material
ambientambient color of material
diffusediffuse color of material
specularspecular color of material
emissionemission color of material
shininessshininess of material
inUseflag whether the material is being used
modethe color material mode of the material

Member Function Documentation

GlsColor Material::GetAmbient ( )

Retrieves the material's ambient color.

Returns
disti::GlsColor containing the ambient color of the material
ColorMaterialMode_e Material::GetColorMaterialMode ( )

Retrieves the material's shininess.

Returns
float containing the shininess of the material
GlsColor Material::GetDiffuse ( )

Retrieves the material's diffuse color.

Returns
disti::GlsColor containing the diffuse color of the material
GlsColor Material::GetEmission ( )

Retrieves the material's emission color.

Returns
disti::GlsColor containing the emission color of the material
String Material::GetName ( )

Retrieves the material's name.

Returns
String containing the name of the material
float Material::GetShininess ( )

Retrieves the material's shininess.

Returns
float containing the shininess of the material
GlsColor Material::GetSpecular ( )

Retrieves the material's specular color.

Returns
disti::GlsColor containing the specular color of the material
void Material::SetAmbient ( GlsColor  ambient)

Sets the material's ambient color.

Parameters
ambientNew ambient color for the material
void Material::SetColorMaterialMode ( ColorMaterialMode_e  mode)

Sets the material's emission color.

Parameters
modeNew color material mode for the material
void Material::SetDiffuse ( GlsColor  diffuse)

Sets the material's diffuse color.

Parameters
diffuseNew diffuse color for the material
void Material::SetEmission ( GlsColor  emission)

Sets the material's emission color.

Parameters
emissionNew emission color for the material
void Material::SetName ( String  name)

Sets the material's name.

Parameters
nameNew name of material
void Material::SetShininess ( float  shininess)

Sets the material's emission color.

Parameters
shininessNew shininess value for the material
void Material::SetSpecular ( GlsColor  specular)

Sets the material's specular color.

Parameters
specularNew specular color for the material

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