unity, access scene ambient

lighting面板里设置的ambient color,在shader里访问是通过UNITY_LIGHTMODEL_AMBIENT这个变量。

它定义在UnityShaderVariables.cginc里。

参考:http://docs.unity3d.com/410/Documentation/Components/SL-BuiltinStateInPrograms.html

原文地址:https://www.cnblogs.com/wantnon/p/5045103.html