Esempio n. 1
0
        bool GetVPMatrix(Light light)
        {
            if (!ShadowUtils.GetVPMatrixWithTags(light, _Tags, _Renderers, out m_ViewMatrix, out m_ProjMatrix, out m_CullingSphere))
            {
                return(false);
            }

            m_MainCharacterShadowMatrix = ShadowUtils.GetShadowTransform(m_ProjMatrix, m_ViewMatrix);

            return(true);
        }
        bool GetVPMatrix(Light light)
        {
            //if (!ShadowUtils.GetVPMatrixWithTags(light, _Tags, _Renderers, out _ViewMatrix, out _ProjMatrix, out _CullingSphere))
            //{
            //    return false;
            //}
            // FIXME: for test
            Bounds bounds = new Bounds(new Vector3(1, 1.65f, 1), new Vector3(0.25f, 0.25f, 0.4f));

            ShadowUtils.GetVPMatrixWithWorldBounds(light, bounds, out _ViewMatrix, out _ProjMatrix, out _CullingSphere);
            _DeepShadowMatrix = ShadowUtils.GetShadowTransform(_ProjMatrix, _ViewMatrix);

            return(true);
        }