List of usage examples for com.badlogic.gdx.backends.android CardboardCamera CardboardCamera
CardboardCamera
From source file:br.com.raphaelbruno.game.zombieinvaders.vr.model.ScreenBase.java
License:Apache License
private void setupEnviroment() { camera = new CardboardCamera(); camera.position.set(0f, CAMERA_Y, 0f); camera.lookAt(0f, CAMERA_Y, -1f);//w w w.j a va2 s .c o m camera.near = Z_NEAR; camera.far = Z_FAR; environment = new Environment(); environment.set(new ColorAttribute(ColorAttribute.AmbientLight, 0.4f, 0.4f, 0.4f, 0.5f)); environment.set(new ColorAttribute(ColorAttribute.Fog, BACKGROUND_COLOR.r, BACKGROUND_COLOR.g, BACKGROUND_COLOR.b, BACKGROUND_COLOR.a)); environment.add(new DirectionalLight().set(0.6f, 0.6f, 0.4f, -0.5f, -0.6f, -0.5f)); environment.add(new DirectionalLight().set(0.6f, 0.6f, 0.4f, 0.5f, -0.6f, 0.5f)); }