فهرست منبع

fixing bug in VRHelper when WebVR is available but no headset

David Rousset 8 سال پیش
والد
کامیت
adf8ed8161
1فایلهای تغییر یافته به همراه4 افزوده شده و 0 حذف شده
  1. 4 0
      src/Cameras/VR/babylon.vrExperienceHelper.ts

+ 4 - 0
src/Cameras/VR/babylon.vrExperienceHelper.ts

@@ -67,6 +67,10 @@ module BABYLON {
                         this._webVRCamera = new BABYLON.WebVRFreeCamera("WebVRHelper", this._position, this._scene);
                         this._webVRsupportedAndReady = true;
                     }
+                    else 
+                    {
+                        this._vrDeviceOrientationCamera = new BABYLON.VRDeviceOrientationFreeCamera("VRDeviceOrientationVRHelper", this._position, this._scene);
+                    }
                     document.body.appendChild(this._btnVR); 
                 });
             }