mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-02-13 11:43:49 +00:00
remove glowbin as it's own render pass
This commit is contained in:
parent
ca5cb3f85f
commit
56e4484ff6
19 changed files with 44 additions and 510 deletions
|
|
@ -197,7 +197,7 @@ void ProcessedMaterial::addStateBlockDesc(const GFXStateBlockDesc& sb)
|
|||
mUserDefined = sb;
|
||||
}
|
||||
|
||||
void ProcessedMaterial::_initStateBlockTemplates(GFXStateBlockDesc& stateTranslucent, GFXStateBlockDesc& stateGlow, GFXStateBlockDesc& stateReflect)
|
||||
void ProcessedMaterial::_initStateBlockTemplates(GFXStateBlockDesc& stateTranslucent, GFXStateBlockDesc& stateReflect)
|
||||
{
|
||||
// Translucency
|
||||
stateTranslucent.blendDefined = true;
|
||||
|
|
@ -211,10 +211,6 @@ void ProcessedMaterial::_initStateBlockTemplates(GFXStateBlockDesc& stateTranslu
|
|||
stateTranslucent.alphaTestFunc = GFXCmpGreaterEqual;
|
||||
stateTranslucent.samplersDefined = true;
|
||||
|
||||
// Glow
|
||||
stateGlow.zDefined = true;
|
||||
stateGlow.zWriteEnable = false;
|
||||
|
||||
// Reflect
|
||||
stateReflect.cullDefined = true;
|
||||
stateReflect.cullMode = mMaterial->mDoubleSided ? GFXCullNone : GFXCullCW;
|
||||
|
|
@ -316,11 +312,10 @@ void ProcessedMaterial::_initPassStateBlock( RenderPassData *rpd, GFXStateBlockD
|
|||
void ProcessedMaterial::_initRenderStateStateBlocks( RenderPassData *rpd )
|
||||
{
|
||||
GFXStateBlockDesc stateTranslucent;
|
||||
GFXStateBlockDesc stateGlow;
|
||||
GFXStateBlockDesc stateReflect;
|
||||
GFXStateBlockDesc statePass;
|
||||
|
||||
_initStateBlockTemplates( stateTranslucent, stateGlow, stateReflect );
|
||||
_initStateBlockTemplates( stateTranslucent, stateReflect );
|
||||
_initPassStateBlock( rpd, statePass );
|
||||
|
||||
// Ok, we've got our templates set up, let's combine them together based on state and
|
||||
|
|
@ -333,8 +328,6 @@ void ProcessedMaterial::_initRenderStateStateBlocks( RenderPassData *rpd )
|
|||
stateFinal.addDesc(stateReflect);
|
||||
if (i & RenderPassData::STATE_TRANSLUCENT)
|
||||
stateFinal.addDesc(stateTranslucent);
|
||||
if (i & RenderPassData::STATE_GLOW)
|
||||
stateFinal.addDesc(stateGlow);
|
||||
|
||||
stateFinal.addDesc(statePass);
|
||||
|
||||
|
|
@ -359,9 +352,6 @@ U32 ProcessedMaterial::_getRenderStateIndex( const SceneRenderState *sceneState,
|
|||
// For example sgData.visibility would be bad to use
|
||||
// in here without changing how RenderMeshMgr works.
|
||||
|
||||
if ( sgData.binType == SceneData::GlowBin )
|
||||
currState |= RenderPassData::STATE_GLOW;
|
||||
|
||||
if ( sceneState && sceneState->isReflectPass() )
|
||||
currState |= RenderPassData::STATE_REFLECT;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue