mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-02-13 03:33:48 +00:00
from @rextimmy new isbackground shader feature. used the same z=w trick we've done before to force things to render behind everything else. applied to fog
This commit is contained in:
parent
dda0cc9aa7
commit
454192ed02
8 changed files with 15 additions and 4 deletions
|
|
@ -575,8 +575,10 @@ void SkyBox::_initRender()
|
|||
mFogBandMat->mDoubleSided = true;
|
||||
mFogBandMat->mEmissive[0] = true;
|
||||
|
||||
FeatureSet features = MATMGR->getDefaultFeatures();
|
||||
features.addFeature(MFT_isBackground);
|
||||
mFogBandMatInst = mFogBandMat->createMatInstance();
|
||||
mFogBandMatInst->init( MATMGR->getDefaultFeatures(), getGFXVertexFormat<GFXVertexPC>() );
|
||||
mFogBandMatInst->init(features, getGFXVertexFormat<GFXVertexPC>() );
|
||||
}
|
||||
|
||||
void SkyBox::onStaticModified( const char *slotName, const char *newValue )
|
||||
|
|
@ -609,6 +611,7 @@ void SkyBox::_initMaterial()
|
|||
FeatureSet features = MATMGR->getDefaultFeatures();
|
||||
features.removeFeature( MFT_RTLighting );
|
||||
features.removeFeature( MFT_Visibility );
|
||||
features.addFeature(MFT_isBackground);
|
||||
features.addFeature(MFT_SkyBox);
|
||||
|
||||
// Now initialize the material.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue