needed mft_pbrconfigmap or _convifgvars and _matinfocflags set to default=true to trip the forward lit side,

shifted the mft_skybox test on down below the checks for the presence of those features to be inserted, and removed them on out if a skybox.
This commit is contained in:
AzaezelX 2019-10-29 22:11:59 -05:00
parent ab613187ed
commit f437dcad45
2 changed files with 15 additions and 12 deletions

View file

@ -43,10 +43,10 @@ ImplementFeatureType( MFT_DetailMap, MFG_Texture, 4.0f, true );
ImplementFeatureType( MFT_DiffuseColor, MFG_Texture, 5.0f, true );
ImplementFeatureType( MFT_DiffuseVertColor, MFG_Texture, 6.0f, true );
ImplementFeatureType( MFT_AlphaTest, MFG_Texture, 7.0f, true );
ImplementFeatureType(MFT_InvertSmoothness, U32(-1), -1, true);
ImplementFeatureType( MFT_PBRConfigMap, MFG_Texture, 8.0f, false );
ImplementFeatureType( MFT_PBRConfigVars, MFG_Texture, 8.0f, false );
ImplementFeatureType( MFT_MatInfoFlags, MFG_Texture, 9.0f, false );
ImplementFeatureType( MFT_InvertSmoothness, U32(-1), -1, true);
ImplementFeatureType( MFT_PBRConfigMap, MFG_Texture, 8.0f, true);
ImplementFeatureType( MFT_PBRConfigVars, MFG_Texture, 8.0f, true);
ImplementFeatureType( MFT_MatInfoFlags, MFG_Texture, 9.0f, true);
ImplementFeatureType( MFT_GlowMap, MFG_Texture, 10.0f, true );
ImplementFeatureType( MFT_NormalMap, MFG_Texture, 11.0f, true );
ImplementFeatureType( MFT_DetailNormalMap, MFG_Texture, 12.0f, true );

View file

@ -385,14 +385,6 @@ void ProcessedShaderMaterial::_determineFeatures( U32 stageNum,
fd.features.addFeature( MFT_CubeMap );
}
if (features.hasFeature(MFT_SkyBox))
{
fd.features.addFeature(MFT_StaticCubemap);
fd.features.addFeature(MFT_CubeMap);
fd.features.addFeature(MFT_SkyBox);
fd.features.removeFeature(MFT_ReflectionProbes);
}
fd.features.addFeature( MFT_Visibility );
if ( lastStage &&
@ -453,6 +445,17 @@ void ProcessedShaderMaterial::_determineFeatures( U32 stageNum,
// Deferred Shading : Material Info Flags
fd.features.addFeature(MFT_MatInfoFlags);
if (features.hasFeature(MFT_SkyBox))
{
fd.features.addFeature(MFT_StaticCubemap);
fd.features.addFeature(MFT_CubeMap);
fd.features.addFeature(MFT_SkyBox);
fd.features.removeFeature(MFT_ReflectionProbes);
fd.features.removeFeature(MFT_PBRConfigVars);
fd.features.removeFeature(MFT_MatInfoFlags);
}
if ( mMaterial->mAccuEnabled[stageNum] )
{
mHasAccumulation = true;