Пример #1
0
        private void PassLightData(IShaderDataOwner light, int lightIndex)
        {
            ShaderUniformManager man = ShaderUniformManager.GetSingleton();

            man.SetArrayData(activeProgram, ShaderUniformName.LightsArray, ShaderUniformName.LightPositionOrDirection, light, lightIndex);
            man.SetArrayData(activeProgram, ShaderUniformName.LightsArray, ShaderUniformName.LightColor, light, lightIndex);
            man.SetArrayData(activeProgram, ShaderUniformName.LightsArray, ShaderUniformName.LinearAttenuation, light, lightIndex);
            man.SetArrayData(activeProgram, ShaderUniformName.LightsArray, ShaderUniformName.QuadraticAttenuation, light, lightIndex);
        }