Browse Source

Fix for mirror cam not being initialized

Rickard Edén 8 years ago
parent
commit
39fad9cb3a
1 changed files with 2 additions and 3 deletions
  1. 2 3
      jme3-vr/src/main/java/com/jme3/app/VREnvironment.java

+ 2 - 3
jme3-vr/src/main/java/com/jme3/app/VREnvironment.java

@@ -73,7 +73,7 @@ public class VREnvironment {
     	
         guiManager   = new VRGuiManager(this);
         mouseManager = new VRMouseManager(this);
-        dummyCam = new Camera(settings.getWidth(), settings.getHeight());
+//        dummyCam = new Camera(settings.getWidth(), settings.getHeight());
         
         processSettings();
     }
@@ -332,7 +332,7 @@ public class VREnvironment {
      */
     public Camera getCamera() {
         if( isInVR() && getVRViewManager() != null && getVRViewManager().getLeftCamera() != null ) {
-            return dummyCam;
+            return getDummyCamera();
         }
         
         return application.getCamera();
@@ -353,7 +353,6 @@ public class VREnvironment {
     			throw new IllegalStateException("VR environment is not attached to any application.");
     		}
     	}
-    	
     	return dummyCam;
     }