public void SetupShadowBaseEffect(MyEffectShadowBase effect) { effect.SetLightViewProjMatrices(m_lightViewProjectionMatrices); effect.SetClipPlanes(m_lightClipPlanes); effect.SetShadowMapSize(new Vector4(ShadowMapCascadeSize * NumSplits, ShadowMapCascadeSize, m_shadowMapCascadeSizeInv.X, m_shadowMapCascadeSizeInv.Y)); effect.SetShadowMap(MyRender.GetRenderTarget(m_shadowRenderTarget)); }
public void SetupShadowBaseEffect(MyEffectShadowBase effect) { //Matrix cameraTransform = Matrix.Invert(MyCamera.ViewMatrix); //effect.SetInvViewMatrix(cameraTransform); effect.SetLightViewProjMatrices(m_lightViewProjectionMatrices); effect.SetClipPlanes(m_lightClipPlanes); effect.SetShadowMapSize(new Vector4(ShadowMapCascadeSize * NumSplits, ShadowMapCascadeSize, m_shadowMapCascadeSizeInv.X, m_shadowMapCascadeSizeInv.Y)); effect.SetShadowMap(MyRender.GetRenderTarget(m_shadowRenderTarget)); }