- fixed Vulkan's uTextureMode setup. Also only mask out the flags we really do not want to avoid surprises in the future.

This commit is contained in:
Christoph Oelckers 2020-04-13 08:54:45 +02:00
parent 9ef6d8fd53
commit 3a47c5c7f7
2 changed files with 2 additions and 2 deletions

View File

@ -128,7 +128,7 @@ bool FGLRenderState::ApplyShader()
activeShader->muFogEnabled.Set(fogset);
int f = mTextureModeFlags;
if (!mBrightmapEnabled) f &= TEXF_Detailmap;
if (!mBrightmapEnabled) f &= ~(TEXF_Brightmap | TEXF_Glowmap);
activeShader->muTextureMode.Set((mTextureMode == TM_NORMAL && mTempTM == TM_OPAQUE ? TM_OPAQUE : mTextureMode) | f);
activeShader->muLightParms.Set(mLightParms);
activeShader->muFogColor.Set(mStreamData.uFogColor);

View File

@ -374,7 +374,7 @@ void VkRenderState::ApplyPushConstants()
mPushConstants.uFogEnabled = fogset;
int f = mTextureModeFlags;
if (!mBrightmapEnabled)
if (!mBrightmapEnabled) f &= ~(TEXF_Brightmap|TEXF_Glowmap);
mPushConstants.uTextureMode = (mTextureMode == TM_NORMAL && tempTM == TM_OPAQUE ? TM_OPAQUE : mTextureMode) | f;
mPushConstants.uLightDist = mLightParms[0];
mPushConstants.uLightFactor = mLightParms[1];