Exemple #1
0
 private void OnDisable()
 {
     if (passThroughSystem != null)
     {
         passThroughSystem.Stop();
     }
     loader            = null;
     passThroughSystem = null;
     cameraTexLeft     = null;
     cameraTexRight    = null;
 }
Exemple #2
0
 void OnEnable()
 {
     loader = XRGeneralSettings.Instance.Manager.activeLoader as PXR_Loader;
     if (loader == null)
     {
         Debug.LogError("Has no XR loader in the project!");
         return;
     }
     passThroughSystem = loader.GetLoadedSubsystem <PXR_PassThroughSystem>();
     if (passThroughSystem == null)
     {
         Debug.LogError("Has no XR Camera subsystem !");
         return;
     }
     passThroughSystem.Start();
 }