Пример #1
0
        public void DisableSession()
        {
            if (!m_IsInitialized)
            {
                return;
            }
#if !UNITY_EDITOR_OSX
            if (NRVirtualDisplayer.RunInBackground)
            {
                if (VirtualDisplayer != null)
                {
                    VirtualDisplayer.Pause();
                }
                NativeAPI.NativeTracking.Pause();
                if (RenderController != null)
                {
                    RenderController.Pause();
                }
            }
            else
            {
                NRDevice.Instance.ForceKill();
            }
#endif
        }
Пример #2
0
        public void DisableSession()
        {
            if (SessionState != SessionState.Running)
            {
                return;
            }
            SessionState = SessionState.Paused;

            if (NRVirtualDisplayer.RunInBackground)
            {
                NRRenderer?.Pause();
                NativeAPI.NativeTracking?.Pause();
                VirtualDisplayer?.Pause();
                NRDevice.Instance.PauseGlassesController();
                NRDevice.Instance.PauseHMD();
            }
            else
            {
                NRDevice.ForceKill();
            }
        }
Пример #3
0
        public void DisableSession()
        {
            if (SessionState != SessionState.Running)
            {
                return;
            }

            // Do not put it in other thread...
            if (NRVirtualDisplayer.RunInBackground)
            {
                NRRenderer?.Pause();
                NativeAPI.NativeTracking?.Pause();
                VirtualDisplayer?.Pause();
                NRDevice.Instance.Pause();
                SessionState = SessionState.Paused;
            }
            else
            {
                NRDevice.ForceKill();
            }
        }
Пример #4
0
 public void DisableSession()
 {
     if (!m_IsInitialized)
     {
         return;
     }
     if (NRVirtualDisplayer.RunInBackground)
     {
         if (VirtualDisplayer != null)
         {
             VirtualDisplayer.Pause();
         }
         NativeAPI.NativeTracking.Pause();
         if (NRRenderer != null)
         {
             NRRenderer.Pause();
         }
     }
     else
     {
         NRDevice.Instance.ForceKill();
     }
 }