ShaderLayer Class Reference

A single layer of a material shader. More...

#include <ishaderlayer.h>

Public Types

enum  Type { DIFFUSE, BLEND }
 

Enumeration of layer types.

More...

Public Member Functions

virtual ~ShaderLayer ()
 Destructor.
virtual Type getType () const =0
 Return the layer type.
virtual qtexture_tgetTexture () const =0
 Return the Texture object corresponding to this layer (may be NULL).
virtual BlendFunc getBlendFunc () const =0
 Return the GL blend function for this layer.
virtual Vector3 getColour () const =0
 Multiplicative layer colour (set with "red 0.6", "green 0.2" etc).
virtual double getAlphaTest () const =0
 Get the alpha test value for this layer.

Detailed Description

A single layer of a material shader.

Each shader layer contains an image texture, a blend mode (e.g. add, modulate) and various other data.

Definition at line 11 of file ishaderlayer.h.


Member Enumeration Documentation

Enumeration of layer types.

Enumerator:
DIFFUSE 
BLEND 

Definition at line 19 of file ishaderlayer.h.


Constructor & Destructor Documentation

virtual ShaderLayer::~ShaderLayer (  )  [inline, virtual]

Destructor.

Definition at line 28 of file ishaderlayer.h.


Member Function Documentation

virtual double ShaderLayer::getAlphaTest (  )  const [pure virtual]

Get the alpha test value for this layer.

Returns:
The alpha test value, between 0.0 and 1.0 if it is set. If no alpha test value is set, -1 will be returned.
virtual BlendFunc ShaderLayer::getBlendFunc (  )  const [pure virtual]

Return the GL blend function for this layer.

Only layers of type BLEND use a BlendFunc. Layers of type DIFFUSE, BUMP and SPECULAR do not use blend functions.

virtual Vector3 ShaderLayer::getColour (  )  const [pure virtual]

Multiplicative layer colour (set with "red 0.6", "green 0.2" etc).

virtual qtexture_t* ShaderLayer::getTexture (  )  const [pure virtual]

Return the Texture object corresponding to this layer (may be NULL).

virtual Type ShaderLayer::getType (  )  const [pure virtual]

Return the layer type.


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

Generated by  doxygen 1.6.2