예제 #1
0
        //在场景loading开始时设置camera statck
        //loading时场景被销毁,这个时候需要将UI摄像机从overlay->base
        public static void SetCameraStackAtLoadingStart(this CameraManagerComponent self)
        {
            var ui_camera = UIManagerComponent.Instance.GetUICamera();

            ui_camera.GetUniversalAdditionalCameraData().renderType = CameraRenderType.Base;
            self.ResetSceneCamera();
        }
예제 #2
0
        public static void SetCameraStackAtLoadingDone(this CameraManagerComponent self)
        {
            self.m_scene_main_camera_go = Camera.main.gameObject;
            self.m_scene_main_camera    = self.m_scene_main_camera_go.GetComponent <Camera>();
            var render = self.m_scene_main_camera.GetUniversalAdditionalCameraData();

            render.renderPostProcessing = true;
            render.renderType           = CameraRenderType.Base;
            render.SetRenderer(1);
            var ui_camera = UIManagerComponent.Instance.GetUICamera();

            __AddOverlayCamera(self.m_scene_main_camera, ui_camera);
        }
예제 #3
0
 public static void  ResetSceneCamera(this CameraManagerComponent self)
 {
     self.m_scene_main_camera_go = null;
     self.m_scene_main_camera    = null;
 }