Go to the documentation of this file.
95 virtual uint32 operator()(
const Pass* p)
const = 0;
232 Real mPointAttenuationCoeffs[3];
273 bool isProgrammable(
void)
const {
return mVertexProgramUsage || mFragmentProgramUsage || mGeometryProgramUsage ||
274 mTesselationHullProgramUsage || mTesselationDomainProgramUsage || mComputeProgramUsage; }
297 size_t calculateSize(
void)
const;
300 unsigned short getIndex(
void)
const {
return mIndex; }
306 void setName(
const String& name);
394 void setShininess(
Real val);
405 void setSelfIllumination(
Real red,
Real green,
Real blue);
413 setSelfIllumination(red, green, blue);
425 void setSelfIllumination(
const ColourValue& selfIllum);
433 setSelfIllumination(emissive);
445 Real getPointSize(
void)
const;
462 void setPointSize(
Real ps);
469 void setPointSpritesEnabled(
bool enabled);
474 bool getPointSpritesEnabled(
void)
const;
493 void setPointAttenuation(
bool enabled,
494 Real constant = 0.0f,
Real linear = 1.0f,
Real quadratic = 0.0f);
497 bool isPointAttenuationEnabled(
void)
const;
500 Real getPointAttenuationConstant(
void)
const;
502 Real getPointAttenuationLinear(
void)
const;
504 Real getPointAttenuationQuadratic(
void)
const;
507 void setPointMinSize(
Real min);
509 Real getPointMinSize(
void)
const;
513 void setPointMaxSize(
Real max);
517 Real getPointMaxSize(
void)
const;
533 const ColourValue& getSelfIllumination(
void)
const;
541 return getSelfIllumination();
546 Real getShininess(
void)
const;
595 unsigned short getTextureUnitStateIndex(
const TextureUnitState* state)
const;
609 void removeTextureUnitState(
unsigned short index);
613 void removeAllTextureUnitStates(
void);
619 return static_cast<unsigned short>(mTextureUnitStates.size());
713 bool hasSeparateSceneBlending()
const;
759 bool hasSeparateSceneBlendingOperations()
const;
768 bool isTransparent(
void)
const;
781 void setDepthCheckEnabled(
bool enabled);
787 bool getDepthCheckEnabled(
void)
const;
799 void setDepthWriteEnabled(
bool enabled);
805 bool getDepthWriteEnabled(
void)
const;
831 void setColourWriteEnabled(
bool enabled);
833 bool getColourWriteEnabled(
void)
const;
883 void setLightingEnabled(
bool enabled);
887 bool getLightingEnabled(
void)
const;
897 void setMaxSimultaneousLights(
unsigned short maxLights);
899 unsigned short getMaxSimultaneousLights(
void)
const;
911 void setStartLight(
unsigned short startLight);
913 unsigned short getStartLight(
void)
const;
916 void setLightMask(
uint32 mask);
918 uint32 getLightMask()
const;
947 mPolygonModeOverrideable =
override;
955 return mPolygonModeOverrideable;
990 Real expDensity = 0.001,
Real linearStart = 0.0,
Real linearEnd = 1.0 );
994 bool getFogOverride(
void)
const;
1000 FogMode getFogMode(
void)
const;
1010 Real getFogStart(
void)
const;
1016 Real getFogEnd(
void)
const;
1022 Real getFogDensity(
void)
const;
1043 void setDepthBias(
float constantBias,
float slopeScaleBias = 0.0f);
1046 float getDepthBiasConstant(
void)
const;
1048 float getDepthBiasSlopeScale(
void)
const;
1055 void setIterationDepthBias(
float biasPerIteration);
1059 float getIterationDepthBias()
const;
1070 void setAlphaRejectSettings(
CompareFunction func,
unsigned char value,
bool alphaToCoverageEnabled =
false);
1078 void setAlphaRejectValue(
unsigned char val);
1095 void setAlphaToCoverageEnabled(
bool enabled);
1113 void setTransparentSortingEnabled(
bool enabled);
1117 bool getTransparentSortingEnabled(
void)
const;
1128 void setTransparentSortingForced(
bool enabled);
1132 bool getTransparentSortingForced(
void)
const;
1176 void setIteratePerLight(
bool enabled,
1196 void setLightCountPerIteration(
unsigned short c);
1200 unsigned short getLightCountPerIteration(
void)
const;
1206 const String& getResourceGroup(
void)
const;
1224 void setVertexProgram(
const String& name,
bool resetParams =
true);
1233 const String& getVertexProgramName(
void)
const;
1269 void setShadowCasterVertexProgram(
const String& name);
1278 const String& getShadowCasterVertexProgramName(
void)
const;
1283 const GpuProgramPtr& getShadowCasterVertexProgram(
void)
const;
1314 void setShadowCasterFragmentProgram(
const String& name);
1323 const String& getShadowCasterFragmentProgramName(
void)
const;
1328 const GpuProgramPtr& getShadowCasterFragmentProgram(
void)
const;
1355 void setShadowReceiverVertexProgram(
const String& name);
1384 void setShadowReceiverFragmentProgram(
const String& name);
1394 const String& getShadowReceiverVertexProgramName(
void)
const;
1399 const GpuProgramPtr& getShadowReceiverVertexProgram(
void)
const;
1402 const String& getShadowReceiverFragmentProgramName(
void)
const;
1407 const GpuProgramPtr& getShadowReceiverFragmentProgram(
void)
const;
1425 void setFragmentProgram(
const String& name,
bool resetParams =
true);
1432 const String& getFragmentProgramName(
void)
const;
1454 void setGeometryProgram(
const String& name,
bool resetParams =
true);
1461 const String& getGeometryProgramName(
void)
const;
1478 Pass* _split(
unsigned short numUnits);
1481 void _notifyIndex(
unsigned short index);
1484 void _prepare(
void);
1486 void _unprepare(
void);
1492 bool isLoaded(
void)
const;
1502 void _dirtyHash(
void);
1509 void _recalculateHash(
void);
1511 void _notifyNeedsRecompile(
void);
1525 unsigned short _getTextureUnitWithContentTypeIndex(
1545 void setTextureAnisotropy(
unsigned int maxAniso);
1566 {
return msDirtyHashList; }
1570 {
return msPassGraveyard; }
1578 static void clearDirtyHashList(
void);
1581 static void processPendingPassUpdates(
void);
1584 void queueForDeletion(
void);
1588 bool isAmbientOnly(
void)
const;
1712 MIN_GPU_PROGRAM_CHANGE
1726 static void setHashFunction(BuiltinHashFunction builtin);
1747 static HashFunc* getBuiltinHashFunction(BuiltinHashFunction builtin);
1778 void setTesselationHullProgram(
const String& name,
bool resetParams =
true);
1785 const String& getTesselationHullProgramName(
void)
const;
1807 void setTesselationDomainProgram(
const String& name,
bool resetParams =
true);
1814 const String& getTesselationDomainProgramName(
void)
const;
1818 const GpuProgramPtr& getTesselationDomainProgram(
void)
const;
1836 void setComputeProgram(
const String& name,
bool resetParams =
true);
1843 const String& getComputeProgramName(
void)
const;
SceneBlendFactor mDestBlendFactor
Pass * pass
The pass to use in this stage.
Definition of a functor for calculating the hashcode of a Pass.
Light::LightTypes mOnlyLightType
GpuProgramUsage * mShadowCasterFragmentProgramUsage
Fragment program details.
bool hasShadowReceiverFragmentProgram(void) const
Returns true if this pass uses a shadow receiver fragment program.
This utility class is used to hold the information used to generate the matrices and other informatio...
Class representing the state of a single texture unit during a Pass of a Technique,...
bool mColourWrite
Colour buffer settings.
Superclass for all objects that wish to use custom memory allocators when their new / delete operator...
const String & getName(void) const
Get the name of the pass.
LightTypes
Defines the type of light.
void setPassIterationCount(const size_t count)
set the number of iterations that this pass should perform when doing fast multi pass operation.
Technique * getParent(void) const
Gets the parent Technique.
bool mSeparateBlendOperation
Determines if we should use separate blending operations for color and alpha channels.
bool mHashDirtyQueued
Pass hash.
bool hasTesselationDomainProgram(void) const
Returns true if this pass uses a programmable tesselation control pipeline.
ShadeOptions mShadeOptions
Shading options.
BuiltinHashFunction
There are some default hash functions used to order passes so that render state changes are minimised...
Try to minimise the number of texture changes.
virtual bool getPolygonModeOverrideable(void) const
Gets whether this renderable's chosen detail level can be overridden (downgraded) by the camera setti...
bool hasGeometryProgram(void) const
Returns true if this pass uses a programmable geometry pipeline.
bool hasFragmentProgram(void) const
Returns true if this pass uses a programmable fragment pipeline.
Concrete IteratorWrapper for nonconst access to the underlying container.
float mDepthBiasSlopeScale
CompareFunction getAlphaRejectFunction(void) const
Gets the alpha reject function.
SceneBlendOperation mAlphaBlendOperation
const ColourValue & getEmissive(void) const
Gets the self illumination colour of the pass.
bool mPointAttenuationEnabled
bool mLightingEnabled
Lighting enabled?
uint32 mHash
Optional name for the pass.
GpuProgramUsage * mShadowCasterVertexProgramUsage
Vertex program details.
Light::LightTypes getOnlyLightType() const
Gets the single light type this pass runs for if getIteratePerLight and getRunOnlyForOneLightType are...
TextureFilterOptions
High-level filtering options providing shortcuts to settings the minification, magnification and mip ...
set< Pass * >::type PassSet
vector< IlluminationPass * >::type IlluminationPassList
bool hasComputeProgram(void) const
Returns true if this pass uses a programmable compute pipeline.
bool mNormaliseNormals
Normalisation.
UserObjectBindings & getUserObjectBindings()
Return an instance of user objects binding associated with this class.
bool isAlphaToCoverageEnabled() const
Gets whether to use alpha to coverage (A2C) when blending alpha rejected values.
Class defining a single pass of a Technique (of a Material), i.e.
Class representing an approach to rendering this particular Material.
bool mQueuedForDeletion
Is this pass queued for deletion?
Class that provides convenient interface to establish a linkage between custom user application objec...
ConstVectorIterator< TextureUnitStates > ConstTextureUnitStateIterator
CompareFunction
Comparison functions used for the depth/stencil buffer operations and others.
unsigned short mMaxSimultaneousLights
Max simultaneous lights.
CompareFunction mDepthFunc
bool mContentTypeLookupBuilt
bool mLightClipPlanes
User clip planes for light?
static void setHashFunction(HashFunc *hashFunc)
Set the hash function used for all passes.
bool hasVertexProgram(void) const
Returns true if this pass uses a programmable vertex pipeline.
GpuProgramUsage * mTesselationDomainProgramUsage
Tesselation domain program details.
IlluminationStage
Categorisation of passes for the purpose of additive lighting.
SceneBlendFactor
Blending factors for manually blending objects with the scene.
void setIlluminationStage(IlluminationStage is)
Manually set which illumination stage this pass is a member of.
VectorIterator< TextureUnitStates > TextureUnitStateIterator
GpuProgramUsage * mTesselationHullProgramUsage
Tesselation hull program details.
bool hasShadowCasterFragmentProgram(void) const
Returns true if this pass uses a shadow caster fragment program.
float mDepthBiasPerIteration
GpuProgramUsage * mGeometryProgramUsage
Geometry program details.
bool hasShadowCasterVertexProgram(void) const
Returns true if this pass uses a shadow caster vertex program.
Part of the rendering which occurs without any kind of direct lighting.
ColourValue mAmbient
Needs to be dirtied when next loaded.
#define OGRE_STATIC_MUTEX(name)
static HashFunc * getHashFunction(void)
Get the hash function used for all passes.
ContentType
Enum identifying the type of content this texture unit contains.
map< String, String >::type AliasTextureNamePairList
Alias / Texture name pair (first = alias, second = texture name)
size_t mPassIterationCount
Number of pass iterations to perform.
bool mPointSpritesEnabled
UserObjectBindings mUserObjectBindings
User objects binding.
GpuProgramUsage * mComputeProgramUsage
Compute program details.
unsigned short mLightsPerIteration
Iterate per how many lights?
bool mTransparentSorting
Transparent depth sorting.
bool mIteratePerLight
Run this pass once per light?
bool mAlphaToCoverageEnabled
static const PassSet & getDirtyHashList(void)
Static method to retrieve all the Passes which need their hash values recalculated.
ContentTypeLookup mShadowContentTypeLookup
Pass * originalPass
The original pass which spawned this one.
void setEmissive(Real red, Real green, Real blue)
Sets the amount of self-illumination an object has.
CullingMode
Hardware culling modes based on vertex winding.
vector< TextureUnitState * >::type TextureUnitStates
Storage of texture unit states.
size_t getPassIterationCount(void) const
Gets the pass iteration count value.
GpuProgramUsage * mVertexProgramUsage
Vertex program details.
void setLightClipPlanesEnabled(bool enabled)
Gets whether or not this pass will be clipped by user clips planes bounding the area covered by the l...
int TrackVertexColourType
An enumeration describing which material properties should track the vertex colours.
static const ColourValue White
bool getLightClipPlanesEnabled() const
Gets whether or not this pass will be clipped by user clips planes bounding the area covered by the l...
bool hasShadowReceiverVertexProgram(void) const
Returns true if this pass uses a shadow receiver vertex program.
Point light sources give off light equally in all directions, so require only position not direction.
Part of the rendering which occurs per light.
PolygonMode mPolygonMode
Polygon mode.
bool getRunOnlyForOneLightType(void) const
Does this pass run only for a single light type (if getIteratePerLight is true).
unsigned short getIndex(void) const
Gets the index of this Pass in the parent Technique.
GpuProgramUsage * mShadowReceiverFragmentProgramUsage
Fragment program details.
GpuProgramUsage * mShadowReceiverVertexProgramUsage
Vertex program details.
uint32 mLightMask
With a specific light mask?
IlluminationStage getIlluminationStage() const
Get the manually assigned illumination stage, if any.
Class representing colour.
bool getIteratePerLight(void) const
Does this pass run once for every light in range?
void setLightScissoringEnabled(bool enabled)
Sets whether or not this pass will be clipped by a scissor rectangle encompassing the lights that are...
unsigned short getNumTextureUnitStates(void) const
Returns the number of texture unit settings.
vector< unsigned short >::type ContentTypeLookup
GpuProgramUsage * mFragmentProgramUsage
Fragment program details.
bool mRunOnlyForOneLightType
Should it only be run for a certain light type?
IlluminationStage mIlluminationStage
Illumination stage?
ShadeOptions
Light shading modes.
virtual ~HashFunc()
Need virtual destructor in case subclasses use it.
bool getLightScissoringEnabled() const
Gets whether or not this pass will be clipped by a scissor rectangle encompassing the lights that are...
This class makes the usage of a vertex and fragment programs (low-level or high-level),...
ManualCullingMode
Manual culling modes based on vertex normals.
virtual void setPolygonModeOverrideable(bool override)
Sets whether this pass's chosen detail level can be overridden (downgraded) by the camera setting.
bool mLightScissoring
Scissoring for the light?
float Real
Software floating point type.
Real mPointSize
Point size, applies when not using per-vertex point size.
uint32 getHash(void) const
Gets the 'hash' of this pass, ie a precomputed number to use for sorting.
bool isProgrammable(void) const
Returns true if this pass is programmable i.e. includes either a vertex or fragment program.
SceneBlendOperation mBlendOperation
TrackVertexColourType mTracking
bool hasTesselationHullProgram(void) const
Returns true if this pass uses a programmable tesselation control pipeline.
Struct recording a pass which can be used for a specific illumination stage.
SceneBlendFactor mDestBlendFactorAlpha
unsigned char mAlphaRejectVal
unsigned char getAlphaRejectValue(void) const
Gets the alpha reject value.
static const PassSet & getPassGraveyard(void)
Static method to retrieve all the Passes which are pending deletion.
ManualCullingMode mManualCullMode
SceneBlendFactor mSourceBlendFactor
CompareFunction mAlphaRejectFunc
bool getNormaliseNormals(void) const
Returns true if this pass has auto-normalisation of normals set.
static PassSet msDirtyHashList
List of Passes whose hashes need recalculating.
const UserObjectBindings & getUserObjectBindings() const
Return an instance of user objects binding associated with this class.
bool mTransparentSortingForced
Transparent depth sorting forced.
static PassSet msPassGraveyard
The place where passes go to die.
PolygonMode
The polygon mode to use when rasterising.
unsigned short mStartLight
Starting light index.
bool destroyOnShutdown
Whether this pass is one which should be deleted itself.
Concrete IteratorWrapper for const access to the underlying container.
void setNormaliseNormals(bool normalise)
If set to true, this forces normals to be normalised dynamically by the hardware for this pass.
bool mPolygonModeOverrideable
void setEmissive(const ColourValue &emissive)
Sets the amount of self-illumination an object has.
SceneBlendFactor mSourceBlendFactorAlpha
SceneBlendType
Types of blending that you can specify between an object and the existing contents of the scene.
SceneBlendOperation
Blending operations controls how objects are blended into the scene.
static HashFunc * msHashFunc
The Pass hash functor.
TextureUnitStates mTextureUnitStates
Copyright © 2012 Torus Knot Software Ltd

This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.