void FRenderState::Reset() { mTextureEnabled = true; mBrightmapEnabled = mFogEnabled = mGlowEnabled = false; mColorMask[0] = mColorMask[1] = mColorMask[2] = mColorMask[3] = true; currentColorMask[0] = currentColorMask[1] = currentColorMask[2] = currentColorMask[3] = true; mFogColor.d = -1; mTextureMode = -1; mLightIndex = -1; mDesaturation = 0; mSrcBlend = GL_SRC_ALPHA; mDstBlend = GL_ONE_MINUS_SRC_ALPHA; mAlphaThreshold = 0.5f; mBlendEquation = GL_FUNC_ADD; mObjectColor = 0xffffffff; m2D = true; mVertexBuffer = mCurrentVertexBuffer = NULL; mColormapState = CM_DEFAULT; mLightParms[3] = -1.f; mSpecialEffect = EFF_NONE; mClipHeightTop = 65536.f; mClipHeightBottom = -65536.f; ClearClipSplit(); stSrcBlend = stDstBlend = -1; stBlendEquation = -1; stAlphaThreshold = -1.f; mLastDepthClamp = true; }
void FRenderState::Reset() { mTextureEnabled = true; mClipLineEnabled = mSplitEnabled = mBrightmapEnabled = mFogEnabled = mGlowEnabled = false; mColorMask[0] = mColorMask[1] = mColorMask[2] = mColorMask[3] = true; currentColorMask[0] = currentColorMask[1] = currentColorMask[2] = currentColorMask[3] = true; mFogColor.d = -1; mTextureMode = -1; mLightIndex = -1; mDesaturation = 0; mSrcBlend = GL_SRC_ALPHA; mDstBlend = GL_ONE_MINUS_SRC_ALPHA; mAlphaThreshold = 0.5f; mBlendEquation = GL_FUNC_ADD; mModelMatrixEnabled = false; mTextureMatrixEnabled = false; mObjectColor = 0xffffffff; mObjectColor2 = 0; mVertexBuffer = mCurrentVertexBuffer = NULL; mColormapState = CM_DEFAULT; mSoftLight = 0; mLightParms[0] = mLightParms[1] = mLightParms[2] = 0.0f; mLightParms[3] = -1.f; mSpecialEffect = EFF_NONE; mClipHeight = 0.f; mClipHeightDirection = 0.f; mShaderTimer = 0.0f; ClearClipSplit(); stSrcBlend = stDstBlend = -1; stBlendEquation = -1; stAlphaThreshold = -1.f; stAlphaTest = 0; mLastDepthClamp = true; mInterpolationFactor = 0.0f; mColor.Set(1.0f, 1.0f, 1.0f, 1.0f); mCameraPos.Set(0.0f, 0.0f, 0.0f, 0.0f); mGlowTop.Set(0.0f, 0.0f, 0.0f, 0.0f); mGlowBottom.Set(0.0f, 0.0f, 0.0f, 0.0f); mGlowTopPlane.Set(0.0f, 0.0f, 0.0f, 0.0f); mGlowBottomPlane.Set(0.0f, 0.0f, 0.0f, 0.0f); mSplitTopPlane.Set(0.0f, 0.0f, 0.0f, 0.0f); mSplitBottomPlane.Set(0.0f, 0.0f, 0.0f, 0.0f); mClipLine.Set(0.0f, 0.0f, 0.0f, 0.0f); mDynColor.Set(0.0f, 0.0f, 0.0f, 0.0f); mEffectState = 0; activeShader = nullptr; mProjectionMatrix.loadIdentity(); mViewMatrix.loadIdentity(); mModelMatrix.loadIdentity(); mTextureMatrix.loadIdentity(); mPassType = NORMAL_PASS; }