Public Member Functions | Protected Attributes

sp::video::TextureLayerStandard Class Reference
[Texture Mapping]

#include <spTextureLayerStandard.hpp>

Inheritance diagram for sp::video::TextureLayerStandard:
sp::video::TextureLayer

List of all members.

Public Member Functions

 TextureLayerStandard ()
virtual ~TextureLayerStandard ()
virtual void bind () const
virtual void unbind () const
virtual void setupDefault () const
virtual bool sortCompare (const TextureLayer *Other) const
virtual bool compare (const TextureLayer *Other) const
void setMappingGen (const EMappingGenTypes Type, bool SetCoordsFlags=true)
void setMatrix (const dim::matrix4f &Matrix)
const dim::matrix4fgetMatrix () const
 Returns the texture matrix. By default the identity matrix.
dim::matrix4fgetMatrix ()
 Returns a reference of the texture matrix.
void setTextureEnv (const ETextureEnvTypes Type)
ETextureEnvTypes getTextureEnv () const
 Returns the texture environment type. By default TEXENV_MODULATE.
EMappingGenTypes getMappingGen () const
 Returns the mapping generation types. By default MAPGEN_DISABLE.
void setMappingGenCoords (s32 CoordsFlags)
s32 getMappingGenCoords () const
 Returns the texture mapping coordinate flags. By default MAPGEN_NONE.

Protected Attributes

dim::matrix4f Matrix_
ETextureEnvTypes EnvType_
EMappingGenTypes MappingGen_
s32 MappingCoords_

Detailed Description

Standard texture layer class. Particular used for fixed-function pipeline.

Since:
Version 3.2

Constructor & Destructor Documentation

sp::video::TextureLayerStandard::TextureLayerStandard (  ) 
sp::video::TextureLayerStandard::~TextureLayerStandard (  )  [virtual]

Member Function Documentation

void sp::video::TextureLayerStandard::bind (  )  const [virtual]

Reimplemented from sp::video::TextureLayer.

bool sp::video::TextureLayerStandard::compare ( const TextureLayer Other  )  const [virtual]

Compares this texture layer with the other one. This should not be used for sorting texture layers.

Parameters:
[in] Other Pointer to the other texture layer object.
Returns:
True if the other layer is logical equal to this layer.
See also:
sortCompare

Reimplemented from sp::video::TextureLayer.

EMappingGenTypes sp::video::TextureLayerStandard::getMappingGen (  )  const [inline]

Returns the mapping generation types. By default MAPGEN_DISABLE.

s32 sp::video::TextureLayerStandard::getMappingGenCoords (  )  const [inline]

Returns the texture mapping coordinate flags. By default MAPGEN_NONE.

const dim::matrix4f& sp::video::TextureLayerStandard::getMatrix (  )  const [inline]

Returns the texture matrix. By default the identity matrix.

dim::matrix4f& sp::video::TextureLayerStandard::getMatrix (  )  [inline]

Returns a reference of the texture matrix.

ETextureEnvTypes sp::video::TextureLayerStandard::getTextureEnv (  )  const [inline]

Returns the texture environment type. By default TEXENV_MODULATE.

void sp::video::TextureLayerStandard::setMappingGen ( const EMappingGenTypes  Type,
bool  SetCoordsFlags = true 
)

Sets the mapping generation types. This describes how the texture coordinates are interpreted. If you don't use a shader, you can use a few pre-defined transformations for texture coordinates instead of using the per-vertex-stored texture coordinates.

Parameters:
[in] Type Specifies the generation type. By default MAPGEN_DISABLE.
[in] SetCoordsFlags Specifies whether the coordinate flags should also be set. Otherwise you have to do this by yourself using the "setMappingGenCoords" function.
See also:
EMappingGenTypes
setMappingGenCoords
void sp::video::TextureLayerStandard::setMappingGenCoords ( s32  CoordsFlags  )  [inline]

Sets the texture mapping coordinate flags. This is used in combination with the mapping generation type.

Parameters:
[in] CoordsFlags Specifies which texture coordinates are to be modified by the mapping generation procedure. This can be a combination of the flags listed in the "EMappingGenCoords" enumeration. By default MAPGEN_NONE.
See also:
EMappingGenCoords
setMappingGen
void sp::video::TextureLayerStandard::setMatrix ( const dim::matrix4f Matrix  )  [inline]

Sets the texture matrix. Use this to transform the texture coordinates.

Parameters:
[in] Matrix Specifies the 4x4 matrix. If your texture coordiantes are only 2-dimensional, the Z component of the matrix will be ignored.
void sp::video::TextureLayerStandard::setTextureEnv ( const ETextureEnvTypes  Type  )  [inline]

Sets the texture environment type. This describes how the texels are combined with the previous pixel colors.

Parameters:
[in] Type Specifies the environment type. By default TEXENV_MODULATE.
See also:
ETextureEnvTypes
void sp::video::TextureLayerStandard::setupDefault (  )  const [virtual]

Sets up the default settings for this layer type. This is used to increase performance by only deactivating texture-layer settings when another layer is activated with a different type of the previous one.

Reimplemented from sp::video::TextureLayer.

bool sp::video::TextureLayerStandard::sortCompare ( const TextureLayer Other  )  const [virtual]

Compares this texture layer with the other one. This is used for sorting texture layers.

Parameters:
[in] Other Pointer to the other texture layer object.
See also:
compare

Reimplemented from sp::video::TextureLayer.

void sp::video::TextureLayerStandard::unbind (  )  const [virtual]

Reimplemented from sp::video::TextureLayer.


Member Data Documentation


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines