Main Page Namespace List Class Hierarchy Alphabetical List Compound List File List Namespace Members Compound Members File Members Related Pages

# Ogre::Technique Class Reference

Class representing an approach to rendering this particular Material. More...

`#include <OgreTechnique.h>`

List of all members.

## Public Types

typedef VectorIterator< Passes > | PassIterator
typedef VectorIterator< IlluminationPassList > | IlluminationPassIterator

## Public Methods

| Technique (Material *parent)
| Constructor.
| Technique (Material *parent, const Technique &oth)
| Copy constructor.
| ~Technique ()
bool | isSupported (void) const
| Indicates if this technique is supported by the current graphics card.
void | _compile (bool autoManageTextureUnits)
| Internal compilation method; see Material::compile.
void | _compileIlluminationPasses (void)
| Internal method for splitting the passes into illumination passes.
Pass * | createPass (void)
| Creates a new Pass for this Technique.
Pass * | getPass (unsigned short index)
| Retrieves the Pass with the given index.
unsigned short | getNumPasses (void) const
| Retrieves the number of passes.
void | removePass (unsigned short index)
| Removes the Pass with the given index.
void | removeAllPasses (void)
| Removes all Passes from this Technique.
const PassIterator | getPassIterator (void)
| Gets an iterator over the passes in this Technique.
const IlluminationPassIterator | getIlluminationPassIterator (void)
| Gets an iterator over the illumination-stage categorised passes.
Material * | getParent (void) const
| Gets the parent Material.
Technique & | operator= (const Technique &rhs)
| Overloaded operator to copy on Technique to another.
bool | isTransparent (void) const
| Returns true if this Technique involves transparency.
void | _load (void)
| Internal load method, derived from call to Material::load.
void | _unload (void)
| Internal unload method, derived from call to Material::unload.
bool | isLoaded (void) const
void | _notifyNeedsRecompile (void)
| Tells the technique that it needs recompilation.
void | setAmbient (Real red, Real green, Real blue)
| Sets the ambient colour reflectance properties for every Pass in every Technique.
void | setAmbient (const ColourValue &ambient)
| Sets the ambient colour reflectance properties for every Pass in every Technique.
void | setDiffuse (Real red, Real green, Real blue, Real alpha)
| Sets the diffuse colour reflectance properties of every Pass in every Technique.
void | setDiffuse (const ColourValue &diffuse)
| Sets the diffuse colour reflectance properties of every Pass in every Technique.
void | setSpecular (Real red, Real green, Real blue, Real alpha)
| Sets the specular colour reflectance properties of every Pass in every Technique.
void | setSpecular (const ColourValue &specular)
| Sets the specular colour reflectance properties of every Pass in every Technique.
void | setShininess (Real val)
| Sets the shininess properties of every Pass in every Technique.
void | setSelfIllumination (Real red, Real green, Real blue)
| Sets the amount of self-illumination of every Pass in every Technique.
void | setSelfIllumination (const ColourValue &selfIllum)
| Sets the amount of self-illumination of every Pass in every Technique.
void | setDepthCheckEnabled (bool enabled)
| Sets whether or not each Pass renders with depth-buffer checking on or not.
void | setDepthWriteEnabled (bool enabled)
| Sets whether or not each Pass renders with depth-buffer writing on or not.
void | setDepthFunction (CompareFunction func)
| Sets the function used to compare depth values when depth checking is on.
void | setColourWriteEnabled (bool enabled)
| Sets whether or not colour buffer writing is enabled for each Pass.
void | setCullingMode (CullingMode mode)
| Sets the culling mode for each pass based on the 'vertex winding'.
void | setManualCullingMode (ManualCullingMode mode)
| Sets the manual culling mode, performed by CPU rather than hardware.
void | setLightingEnabled (bool enabled)
| Sets whether or not dynamic lighting is enabled for every Pass.
void | setShadingMode (ShadeOptions mode)
| Sets the type of light shading required.
void | setFog (bool overrideScene, FogMode mode=FOG_NONE, const ColourValue &colour=ColourValue::White, Real expDensity=0.001, Real linearStart=0.0, Real linearEnd=1.0)
| Sets the fogging mode applied to each pass.
void | setDepthBias (ushort bias)
| Sets the depth bias to be used for each Pass.
void | setTextureFiltering (TextureFilterOptions filterType)
| Set texture filtering for every texture unit in every Pass.
void | setTextureAnisotropy (unsigned int maxAniso)
| Sets the anisotropy level to be used for all textures.
void | setSceneBlending (const SceneBlendType sbt)
| Sets the kind of blending every pass has with the existing contents of the scene.
void | setSceneBlending (const SceneBlendFactor sourceFactor, const SceneBlendFactor destFactor)
| Allows very fine control of blending every Pass with the existing contents of the scene.
void | setLodIndex (unsigned short index)
| Assigns a level-of-detail (LOD) index to this Technique.
unsigned short | getLodIndex (void) const
| Gets the level-of-detail index assigned to this Technique.
bool | isDepthWriteEnabled (void) const
| Is depth writing going to occur on this technique?
bool | isDepthCheckEnabled (void) const
| Is depth checking going to occur on this technique?

## Protected Types

typedef std::vector< Pass * > | Passes

## Protected Methods

void | clearIlluminationPasses (void)
| Internal method for clearing illumination pass list.

## Protected Attributes

Passes | mPasses
| List of primary passes.
IlluminationPassList | mIlluminationPasses
| List of derived passes, categorised into IlluminationStage (ordered).
Material * | mParent
bool | mIsSupported
unsigned short | mLodIndex

## Detailed Description

Class representing an approach to rendering this particular Material.

Remarks:
  Ogre will attempt to use the best technique supported by the active hardware, unless you specifically request a lower detail technique (say for distant rendering).

Definition at line 41 of file OgreTechnique.h.

## Member Typedef Documentation

typedef VectorIterator<IlluminationPassList> Ogre::Technique::IlluminationPassIterator

| Definition at line 95 of file OgreTechnique.h. Referenced by getIlluminationPassIterator().

typedef std::vector<Pass*> Ogre::Technique::Passes`[protected]`

| Definition at line 44 of file OgreTechnique.h.

typedef VectorIterator<Passes> Ogre::Technique::PassIterator

| Definition at line 92 of file OgreTechnique.h. Referenced by getPassIterator().

## Constructor & Destructor Documentation

Ogre::Technique::Technique | ( | Material * | parent | ) |

| Constructor. Definition at line 38 of file OgreTechnique.cpp.

Ogre::Technique::Technique | ( | Material * | parent,
|  | const Technique & | oth
| ) |

| Copy constructor. Definition at line 44 of file OgreTechnique.cpp.

Ogre::Technique::~Technique | ( |  | ) |

| Definition at line 51 of file OgreTechnique.cpp. References clearIlluminationPasses(), and removeAllPasses().

## Member Function Documentation

void Ogre::Technique::_compile | ( | bool | autoManageTextureUnits | ) |

Internal compilation method; see Material::compile.

Definition at line 62 of file OgreTechnique.cpp.

References _compileIlluminationPasses(), Ogre::Pass::_split(), Ogre::TextureUnitState::getColourBlendMode(), Ogre::Pass::getFragmentProgram(), Ogre::RenderSystemCapabilities::getNumTextureUnits(), Ogre::Pass::getNumTextureUnitStates(), Ogre::Pass::getTextureUnitStateIterator(), Ogre::Pass::getVertexProgram(), Ogre::RenderSystemCapabilities::hasCapability(), Ogre::Pass::hasFragmentProgram(), Ogre::Pass::hasVertexProgram(), Ogre::TextureUnitState::is3D(), Ogre::GpuProgram::isSupported(), Ogre::LBX_DOTPRODUCT, mIsSupported, mPasses, Ogre::LayerBlendModeEx::operation, Ogre::RSC_CUBEMAPPING, and Ogre::RSC_DOT3.

void Ogre::Technique::_compileIlluminationPasses | ( | void |  | ) |

Internal method for splitting the passes into illumination passes.

Definition at line 498 of file OgreTechnique.cpp.

References clearIlluminationPasses(), Ogre::IlluminationPass::destroyOnShutdown, Ogre::Pass::getAmbient(), Ogre::Pass::getDiffuse(), Ogre::Pass::getIndex(), Ogre::Pass::getLightingEnabled(), Ogre::Pass::getNumTextureUnitStates(), Ogre::Pass::getRunOncePerLight(), Ogre::Pass::getSelfIllumination(), Ogre::Pass::getSpecular(), Ogre::Pass::hasFragmentProgram(), Ogre::IlluminationStage, Ogre::IS_AMBIENT, Ogre::IS_DECAL, Ogre::IS_PER_LIGHT, Ogre::Pass::isAmbientOnly(), isTransparent(), mIlluminationPasses, mPasses, Ogre::IlluminationPass::originalPass, Ogre::IlluminationPass::pass, Ogre::Pass::removeAllTextureUnitStates(), Ogre::SBF_DEST_COLOUR, Ogre::SBF_ONE, Ogre::SBF_ZERO, Ogre::Pass::setAmbient(), Ogre::Pass::setColourWriteEnabled(), Ogre::Pass::setDiffuse(), Ogre::Pass::setFragmentProgram(), Ogre::Pass::setLightingEnabled(), Ogre::Pass::setSceneBlending(), Ogre::Pass::setSelfIllumination(), Ogre::Pass::setSpecular(), and Ogre::IlluminationPass::stage.

Referenced by _compile(), and operator=().

void Ogre::Technique::_load | ( | void |  | ) |

| Internal load method, derived from call to Material::load. Definition at line 245 of file OgreTechnique.cpp. References mIsSupported, and mPasses.

void Ogre::Technique::_notifyNeedsRecompile | ( | void |  | ) |

Tells the technique that it needs recompilation.

Definition at line 487 of file OgreTechnique.cpp.

References Ogre::Material::_notifyNeedsRecompile(), and mParent.

Referenced by Ogre::Pass::_notifyNeedsRecompile(), Ogre::Pass::addTextureUnitState(), Ogre::Pass::createTextureUnitState(), Ogre::Pass::removeAllTextureUnitStates(), Ogre::Pass::removeTextureUnitState(), Ogre::Pass::setFragmentProgram(), setLodIndex(), Ogre::Pass::setShadowCasterVertexProgram(), Ogre::Pass::setShadowReceiverVertexProgram(), and Ogre::Pass::setVertexProgram().

void Ogre::Technique::_unload | ( | void |  | ) |

| Internal unload method, derived from call to Material::unload. Definition at line 257 of file OgreTechnique.cpp. References mPasses.

void Ogre::Technique::clearIlluminationPasses | ( | void |  | ) | `[protected]`

| Internal method for clearing illumination pass list. Definition at line 685 of file OgreTechnique.cpp. References mIlluminationPasses. Referenced by _compileIlluminationPasses(), and ~Technique().

Pass * Ogre::Technique::createPass | ( | void |  | ) |

Creates a new Pass for this Technique.

Remarks:
  A Pass is a single rendering pass, ie a single draw of the given material. Note that if you create a pass without a fragment program, during compilation of the material the pass may be split into multiple passes if the graphics card cannot handle the number of texture units requested. For passes with fragment programs, however, the number of passes you create will never be altered, so you have to make sure that you create an alternative fallback Technique for if a card does not have enough facilities for what you're asking for.

Definition at line 146 of file OgreTechnique.cpp.

References mPasses.

Referenced by Ogre::Pass::_split(), and Ogre::parsePass().

const Technique::IlluminationPassIterator Ogre::Technique::getIlluminationPassIterator | ( | void |  | ) |

| Gets an iterator over the illumination-stage categorised passes. Definition at line 701 of file OgreTechnique.cpp. References IlluminationPassIterator, and mIlluminationPasses. Referenced by Ogre::RenderPriorityGroup::addSolidRenderableSplitByLightType().

unsigned short Ogre::Technique::getLodIndex | ( | void |  | ) | const

| Gets the level-of-detail index assigned to this Technique. Definition at line 382 of file OgreTechnique.h. Referenced by Ogre::Material::operator=().

unsigned short Ogre::Technique::getNumPasses | ( | void |  | ) | const

| Retrieves the number of passes. Definition at line 159 of file OgreTechnique.cpp. References mPasses. Referenced by Ogre::TerrainSceneManager::setupTerrainMaterial().

Material* Ogre::Technique::getParent | ( | void |  | ) | const

| Gets the parent Material. Definition at line 99 of file OgreTechnique.h. Referenced by Ogre::RenderPriorityGroup::addRenderable(), and Ogre::SceneManager::renderTransparentShadowCasterObjects().

Pass * Ogre::Technique::getPass | ( | unsigned short | index | ) |

Retrieves the Pass with the given index.

Definition at line 153 of file OgreTechnique.cpp.

References mPasses.

Referenced by Ogre::Quake3Shader::createAsMaterial(), Ogre::SceneManager::createShadowTextures(), Ogre::Font::createTextureFromFont(), Ogre::SceneManager::initShadowVolumeMaterials(), Ogre::Font::load(), Ogre::BspLevel::loadQuake3Level(), Ogre::BspSceneManager::processVisibleLeaf(), Ogre::Entity::reevaluateVertexProcessing(), Ogre::SceneManager::setSkyBox(), Ogre::TerrainSceneManager::setupTerrainMaterial(), and Ogre::PanelGuiElement::updateTextureGeometry().

const Technique::PassIterator Ogre::Technique::getPassIterator | ( | void |  | ) |

| Gets an iterator over the passes in this Technique. Definition at line 183 of file OgreTechnique.cpp. References mPasses, and PassIterator. Referenced by Ogre::RenderPriorityGroup::addSolidRenderable(), Ogre::RenderPriorityGroup::addTransparentRenderable(), and Ogre::BspSceneManager::renderStaticGeometry().

bool Ogre::Technique::isDepthCheckEnabled | ( | void |  | ) | const

| Is depth checking going to occur on this technique? Definition at line 232 of file OgreTechnique.cpp. References mPasses. Referenced by Ogre::RenderPriorityGroup::addRenderable().

bool Ogre::Technique::isDepthWriteEnabled | ( | void |  | ) | const

| Is depth writing going to occur on this technique? Definition at line 219 of file OgreTechnique.cpp. References mPasses. Referenced by Ogre::RenderPriorityGroup::addRenderable().

bool Ogre::Technique::isLoaded | ( | void |  | ) | const

| Definition at line 268 of file OgreTechnique.cpp. References Ogre::Resource::isLoaded(), and mParent. Referenced by Ogre::Pass::isLoaded().

bool Ogre::Technique::isSupported | ( | void |  | ) | const

Indicates if this technique is supported by the current graphics card.

Remarks:
  This will only be correct after the Technique has been compiled, which is usually done from Material::compile.

Definition at line 57 of file OgreTechnique.cpp.

References mIsSupported.

bool Ogre::Technique::isTransparent | ( | void |  | ) | const

Returns true if this Technique involves transparency.

Remarks:
  This basically boils down to whether the first pass has a scene blending factor. Even if the other passes do not, the base colour, including parts of the original scene, may be used for blending, therefore we have to treat the whole Technique as transparent.

Definition at line 206 of file OgreTechnique.cpp.

References mPasses.

Referenced by _compileIlluminationPasses(), and Ogre::RenderPriorityGroup::addRenderable().

Technique & Ogre::Technique::operator= | ( | const Technique & | rhs | ) |

| Overloaded operator to copy on Technique to another. Definition at line 188 of file OgreTechnique.cpp. References _compileIlluminationPasses(), mIsSupported, mLodIndex, mPasses, and removeAllPasses().

void Ogre::Technique::removeAllPasses | ( | void |  | ) |

| Removes all Passes from this Technique. Definition at line 172 of file OgreTechnique.cpp. References mPasses. Referenced by operator=(), and ~Technique().

void Ogre::Technique::removePass | ( | unsigned short | index | ) |

| Removes the Pass with the given index. Definition at line 164 of file OgreTechnique.cpp. References mPasses.

void Ogre::Technique::setAmbient | ( | const ColourValue & | ambient | ) |

Sets the ambient colour reflectance properties for every Pass in every Technique.

Note:
  This property actually exists on the Pass class. For simplicity, this method allows you to set these properties for every current Pass within this Technique. If you need more precision, retrieve the Pass instance and set the property there.

See also:
  Pass::setAmbient

Definition at line 284 of file OgreTechnique.cpp.

References Ogre::ColourValue::b, Ogre::ColourValue::g, Ogre::ColourValue::r, and setAmbient().

void Ogre::Technique::setAmbient | ( | Real | red,
|  | Real | green,
|  | Real | blue
| ) |

Sets the ambient colour reflectance properties for every Pass in every Technique.

Note:
  This property actually exists on the Pass class. For simplicity, this method allows you to set these properties for every current Pass within this Technique. If you need more precision, retrieve the Pass instance and set the property there.

See also:
  Pass::setAmbient

Definition at line 273 of file OgreTechnique.cpp.

References Ogre::green, mPasses, and Ogre::Real.

Referenced by setAmbient().

void Ogre::Technique::setColourWriteEnabled | ( | bool | enabled | ) |

Sets whether or not colour buffer writing is enabled for each Pass.

Note:
  This property actually exists on the Pass class. For simplicity, this method allows you to set these properties for every current Pass within this Technique. If you need more precision, retrieve the Pass instance and set the property there.

See also:
  Pass::setColourWriteEnabled

Definition at line 374 of file OgreTechnique.cpp.

References mPasses.

void Ogre::Technique::setCullingMode | ( | CullingMode | mode | ) |

Sets the culling mode for each pass based on the 'vertex winding'.

Note:
  This property actually exists on the Pass class. For simplicity, this method allows you to set these properties for every current Pass within this Technique. If you need more precision, retrieve the Pass instance and set the property there.

See also:
  Pass::setCullingMode

Definition at line 384 of file OgreTechnique.cpp.

References Ogre::CullingMode, and mPasses.

void Ogre::Technique::setDepthBias | ( | ushort | bias | ) |

Sets the depth bias to be used for each Pass.

Note:
  This property actually exists on the Pass class. For simplicity, this method allows you to set these properties for every current Pass within this Technique. If you need more precision, retrieve the Pass instance and set the property there.

See also:
  Pass::setDepthBias

Definition at line 435 of file OgreTechnique.cpp.

References mPasses, and Ogre::ushort.

void Ogre::Technique::setDepthCheckEnabled | ( | bool | enabled | ) |

Sets whether or not each Pass renders with depth-buffer checking on or not.

Note:
  This property actually exists on the Pass class. For simplicity, this method allows you to set these properties for every current Pass within this Technique. If you need more precision, retrieve the Pass instance and set the property there.

See also:
  Pass::setDepthCheckEnabled

Definition at line 344 of file OgreTechnique.cpp.

References mPasses.

void Ogre::Technique::setDepthFunction | ( | CompareFunction | func | ) |

Sets the function used to compare depth values when depth checking is on.

Note:
  This property actually exists on the Pass class. For simplicity, this method allows you to set these properties for every current Pass within this Technique. If you need more precision, retrieve the Pass instance and set the property there.

See also:
  Pass::setDepthFunction

Definition at line 364 of file OgreTechnique.cpp.

References Ogre::CompareFunction, and mPasses.

void Ogre::Technique::setDepthWriteEnabled | ( | bool | enabled | ) |

Sets whether or not each Pass renders with depth-buffer writing on or not.

Note:
  This property actually exists on the Pass class. For simplicity, this method allows you to set these properties for every current Pass within this Technique. If you need more precision, retrieve the Pass instance and set the property there.

See also:
  Pass::setDepthWriteEnabled

Definition at line 354 of file OgreTechnique.cpp.

References mPasses.

void Ogre::Technique::setDiffuse | ( | const ColourValue & | diffuse | ) |

Sets the diffuse colour reflectance properties of every Pass in every Technique.

Note:
  This property actually exists on the Pass class. For simplicity, this method allows you to set these properties for every current Pass within this Technique. If you need more precision, retrieve the Pass instance and set the property there.

See also:
  Pass::setDiffuse

Definition at line 299 of file OgreTechnique.cpp.

References Ogre::ColourValue::a, Ogre::ColourValue::b, Ogre::ColourValue::g, Ogre::ColourValue::r, and setDiffuse().

void Ogre::Technique::setDiffuse | ( | Real | red,
|  | Real | green,
|  | Real | blue,
|  | Real | alpha
| ) |

Sets the diffuse colour reflectance properties of every Pass in every Technique.

Note:
  This property actually exists on the Pass class. For simplicity, this method allows you to set these properties for every current Pass within this Technique. If you need more precision, retrieve the Pass instance and set the property there.

See also:
  Pass::setDiffuse

Definition at line 289 of file OgreTechnique.cpp.

References Ogre::green, mPasses, and Ogre::Real.

Referenced by setDiffuse().

void Ogre::Technique::setFog | ( | bool | overrideScene,
|  | FogMode | mode = FOG_NONE,
|  | const ColourValue & | colour = ColourValue::White,
|  | Real | expDensity = 0.001,
|  | Real | linearStart = 0.0,
|  | Real | linearEnd = 1.0
| ) |

Sets the fogging mode applied to each pass.

Note:
  This property actually exists on the Pass class. For simplicity, this method allows you to set these properties for every current Pass within this Technique. If you need more precision, retrieve the Pass instance and set the property there.

See also:
  Pass::setFog

Definition at line 424 of file OgreTechnique.cpp.

References Ogre::FogMode, mPasses, and Ogre::Real.

void Ogre::Technique::setLightingEnabled | ( | bool | enabled | ) |

Sets whether or not dynamic lighting is enabled for every Pass.

Note:
  This property actually exists on the Pass class. For simplicity, this method allows you to set these properties for every current Pass within this Technique. If you need more precision, retrieve the Pass instance and set the property there.

See also:
  Pass::setLightingEnabled

Definition at line 404 of file OgreTechnique.cpp.

References mPasses.

void Ogre::Technique::setLodIndex | ( | unsigned short | index | ) |

Assigns a level-of-detail (LOD) index to this Technique.

Remarks:
  As noted previously, as well as providing fallback support for various graphics cards, multiple Technique objects can also be used to implement material LOD, where the detail of the material diminishes with distance to save rendering power.

  By default, all Techniques have a LOD index of 0, which means they are the highest level of detail. Increasing LOD indexes are lower levels of detail. You can assign more than one Technique to the same LOD index, meaning that the best Technique that is supported at that LOD index is used.

  You should not leave gaps in the LOD sequence; Ogre will allow you to do this and will continue to function as if the LODs were sequential, but it will confuse matters.

Definition at line 492 of file OgreTechnique.cpp.

References _notifyNeedsRecompile(), and mLodIndex.

Referenced by Ogre::parseLodIndex().

void Ogre::Technique::setManualCullingMode | ( | ManualCullingMode | mode | ) |

Sets the manual culling mode, performed by CPU rather than hardware.

Note:
  This property actually exists on the Pass class. For simplicity, this method allows you to set these properties for every current Pass within this Technique. If you need more precision, retrieve the Pass instance and set the property there.

See also:
  Pass::setManualCullingMode

Definition at line 394 of file OgreTechnique.cpp.

References Ogre::ManualCullingMode, and mPasses.

void Ogre::Technique::setSceneBlending | ( | const SceneBlendFactor | sourceFactor,
|  | const SceneBlendFactor | destFactor
| ) |

Allows very fine control of blending every Pass with the existing contents of the scene.

Note:
  This property actually exists on the Pass class. For simplicity, this method allows you to set these properties for every current Pass within this Technique. If you need more precision, retrieve the Pass instance and set the property there.

See also:
  Pass::setSceneBlending

Definition at line 475 of file OgreTechnique.cpp.

References mPasses, and Ogre::SceneBlendFactor.

void Ogre::Technique::setSceneBlending | ( | const SceneBlendType | sbt | ) |

Sets the kind of blending every pass has with the existing contents of the scene.

Note:
  This property actually exists on the Pass class. For simplicity, this method allows you to set these properties for every current Pass within this Technique. If you need more precision, retrieve the Pass instance and set the property there.

See also:
  Pass::setSceneBlending

Definition at line 465 of file OgreTechnique.cpp.

References mPasses, and Ogre::SceneBlendType.

void Ogre::Technique::setSelfIllumination | ( | const ColourValue & | selfIllum | ) |

Sets the amount of self-illumination of every Pass in every Technique.

Note:
  This property actually exists on the Pass class. For simplicity, this method allows you to set these properties for every current Pass within this Technique. If you need more precision, retrieve the Pass instance and set the property there.

See also:
  Pass::setSelfIllumination

Definition at line 339 of file OgreTechnique.cpp.

References Ogre::ColourValue::b, Ogre::ColourValue::g, Ogre::ColourValue::r, and setSelfIllumination().

void Ogre::Technique::setSelfIllumination | ( | Real | red,
|  | Real | green,
|  | Real | blue
| ) |

Sets the amount of self-illumination of every Pass in every Technique.

Note:
  This property actually exists on the Pass class. For simplicity, this method allows you to set these properties for every current Pass within this Technique. If you need more precision, retrieve the Pass instance and set the property there.

See also:
  Pass::setSelfIllumination

Definition at line 329 of file OgreTechnique.cpp.

References Ogre::green, mPasses, and Ogre::Real.

Referenced by setSelfIllumination().

void Ogre::Technique::setShadingMode | ( | ShadeOptions | mode | ) |

Sets the type of light shading required.

Note:
  This property actually exists on the Pass class. For simplicity, this method allows you to set these properties for every current Pass within this Technique. If you need more precision, retrieve the Pass instance and set the property there.

See also:
  Pass::setShadingMode

Definition at line 414 of file OgreTechnique.cpp.

References mPasses, and Ogre::ShadeOptions.

void Ogre::Technique::setShininess | ( | Real | val | ) |

Sets the shininess properties of every Pass in every Technique.

Note:
  This property actually exists on the Pass class. For simplicity, this method allows you to set these properties for every current Pass within this Technique. If you need more precision, retrieve the Pass instance and set the property there.

See also:
  Pass::setShininess

Definition at line 319 of file OgreTechnique.cpp.

References mPasses, and Ogre::Real.

void Ogre::Technique::setSpecular | ( | const ColourValue & | specular | ) |

Sets the specular colour reflectance properties of every Pass in every Technique.

Note:
  This property actually exists on the Pass class. For simplicity, this method allows you to set these properties for every current Pass within this Technique. If you need more precision, retrieve the Pass instance and set the property there.

See also:
  Pass::setSpecular

Definition at line 314 of file OgreTechnique.cpp.

References Ogre::ColourValue::a, Ogre::ColourValue::b, Ogre::ColourValue::g, Ogre::ColourValue::r, and setSpecular().

void Ogre::Technique::setSpecular | ( | Real | red,
|  | Real | green,
|  | Real | blue,
|  | Real | alpha
| ) |

Sets the specular colour reflectance properties of every Pass in every Technique.

Note:
  This property actually exists on the Pass class. For simplicity, this method allows you to set these properties for every current Pass within this Technique. If you need more precision, retrieve the Pass instance and set the property there.

See also:
  Pass::setSpecular

Definition at line 304 of file OgreTechnique.cpp.

References Ogre::green, mPasses, and Ogre::Real.

Referenced by setSpecular().

void Ogre::Technique::setTextureAnisotropy | ( | unsigned int | maxAniso | ) |

Sets the anisotropy level to be used for all textures.

Note:
  This property has been moved to the TextureUnitState class, which is accessible via the Technique and Pass. For simplicity, this method allows you to set these properties for every current TeextureUnitState, If you need more precision, retrieve the Technique, Pass and TextureUnitState instances and set the property there.

See also:
  TextureUnitState::setTextureAnisotropy

Definition at line 455 of file OgreTechnique.cpp.

References mPasses.

void Ogre::Technique::setTextureFiltering | ( | TextureFilterOptions | filterType | ) |

Set texture filtering for every texture unit in every Pass.

Note:
  This property actually exists on the TextureUnitState class For simplicity, this method allows you to set these properties for every current TeextureUnitState, If you need more precision, retrieve the Pass and TextureUnitState instances and set the property there.

See also:
  TextureUnitState::setTextureFiltering

Definition at line 445 of file OgreTechnique.cpp.

References mPasses, and Ogre::TextureFilterOptions.

## Member Data Documentation

IlluminationPassList Ogre::Technique::mIlluminationPasses`[protected]`

| List of derived passes, categorised into IlluminationStage (ordered). Definition at line 48 of file OgreTechnique.h. Referenced by _compileIlluminationPasses(), clearIlluminationPasses(), and getIlluminationPassIterator().

bool Ogre::Technique::mIsSupported`[protected]`

| Definition at line 50 of file OgreTechnique.h. Referenced by _compile(), _load(), isSupported(), and operator=().

unsigned short Ogre::Technique::mLodIndex`[protected]`

| Definition at line 51 of file OgreTechnique.h. Referenced by operator=(), and setLodIndex().

Material* Ogre::Technique::mParent`[protected]`

| Definition at line 49 of file OgreTechnique.h. Referenced by _notifyNeedsRecompile(), and isLoaded().

Passes Ogre::Technique::mPasses`[protected]`

List of primary passes.

Definition at line 46 of file OgreTechnique.h.

Referenced by _compile(), _compileIlluminationPasses(), _load(), _unload(), createPass(), getNumPasses(), getPass(), getPassIterator(), isDepthCheckEnabled(), isDepthWriteEnabled(), isTransparent(), operator=(), removeAllPasses(), removePass(), setAmbient(), setColourWriteEnabled(), setCullingMode(), setDepthBias(), setDepthCheckEnabled(), setDepthFunction(), setDepthWriteEnabled(), setDiffuse(), setFog(), setLightingEnabled(), setManualCullingMode(), setSceneBlending(), setSelfIllumination(), setShadingMode(), setShininess(), setSpecular(), setTextureAnisotropy(), and setTextureFiltering().

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

- OgreTechnique.h
- OgreTechnique.cpp

Copyright © 2002-2003 by The OGRE Team
Last modified Sun Nov 28 19:51:43 2004