示例#1
0
    public static void SettingCamera(Camera camera, int sceneID)
    {
        Scene scene = DataReader <Scene> .Get(sceneID);

        if (scene == null)
        {
            return;
        }
        string[] array = scene.clip.Split(";".ToCharArray());
        if (array.Length >= 2)
        {
            CamerasMgr.CameraMain.set_nearClipPlane(float.Parse(array[0]));
            CamerasMgr.CameraMain.set_farClipPlane(float.Parse(array[1]));
        }
        CamerasMgr.CameraMain.set_fieldOfView((float)scene.CameraWideAngle);
        CameraSetting.SetCameraLayerCullDistances(scene);
    }