If you use the GWT plugin in Eclipse and don’t run your GWT project via Gradle, make sure you update your GWT plugin to version 2.8.0.

gdx-vr

In other news, I’ve been working on some VR related projects recently. Our friends from LWJGL have created wrapper for OpenVR, Valve’s SDK to talk to all kinds of VR hardware, from Oculus to the HTC Vive. I’ve built a libGDX specific wrapper on top of the OpenVR bindings, which should make working on VR projects with libGDX a little simpler.

There are a few caveats. OpenVR is currently really only working on Windows. OpenVR on Mac appears to be broken. Valve has released support for Linux a few weeks ago, I did not have time to test this yet. It should however just work out of the box.

Another caveat is the way rendering is performed currently. For each eye, a separate frame buffer is created. Rendering as in the example is then performed for each framebuffer, using a separate camera/projection matrix for each eye, essentially drawing the scene twice. With a 11ms/frame budget, that can be problematic if you have thousands of draw calls to render a scene for one eye, as it doubles the CPU/driver work in the VR case. Ideally, you only issue one batch of draw calls for both eyes, using instancing and a simple trick involving clipping planes in the vertex shader to redirect the rendering to either the left or right side of the combined frame buffer. Long story short: gdx-vr plus the libGDX 3D API will take you a long way, but for more complex stuff, you’ll have to get your hands dirty with custom rendering.

The frame buffers allocated per eye aren’t setup to use MSAA at the moment. The probpem with MSAA is that it’s no good for deferred rendering (not a problem with libGDX’s current 3D API, which is a basic forward renderer).

The final caveat is that the project hasn’t been released to Maven Central yet, and hardcodes dependencies on LWJGL version 3.1.2-SNAPSHOT. Once LWJGL 3.1.2 is released, I’ll also release gdx-vr to Maven Central, with its version synched to the libGDX version that uses LWJGL 3.1.2. For now, you can just import gdx-vr as a Maven project into the IDE of choice, play around with the sample or integrate it in your own project.

I have not made this an official extension yet, as the implementation currently only supports desktop system. I’ve received a Google Daydream and am looking into abstracting the gdx-vr API enough to have multiple backends, like any good extension citizen.

Christmas is almost here. Have a libGDX release. Here’s what’s new (plus a ton of bug fixes, see the commit logs on GitHub).

[1.9.5]
- Upgraded to MobiDevelop's RoboVM fork version 2.3.0, update your
- Upgraded to GWT 2.8.0 for faster compiles and better compile output
- Fix NPE swallowing "video driver unsupported" error on LWJGL 2 backend.
- Allow window icons to be set in Lwjgl3ApplicationConfiguration or Lwjgl3WindowConfiguration.
- Allow window icon and title to be changed in Lwjgl3Window
- API Addition: ApplicationLogger interface, allowing easier access to custom logging
- DefaultRenderableSorter accounts for center of Renderable mesh, see https://github.com/libgdx/libgdx/pull/4319
- Bullet: added FilterableVehicleRaycaster, see https://github.com/libgdx/libgdx/pull/4361
- Bullet: updated to 2.85, see: http://bulletphysics.org/wordpress/?p=456
- Updated iOS native build scripts to iOS 10.1 and TVOS 10.0
- API Addition: BitmapFont#blankLineScale.
- Fixed rounding of Drawables in ProgressBar. Allow rounding to be disabled with setRound().
- Updated LWJGL3 backend to LWJGL 3.1.0, see https://blog.lwjgl.org/lwjgl-3-1-0-released/
- LWJGL3 backend now supports non-continuous rendering, see https://github.com/libgdx/libgdx/pull/3772
- API Change: Lwjgl3WindowListener.refreshRequested() is called when the windowing system (GLFW) reports contents of a window are dirty and need to be redrawn.
- API Change: Lwjgl3WindowListener.maximized() is called when a window enters or exits a maximized state.
- API Change: Lwjgl3WindowListener.deiconified() removed, combined with .iconified().
- API Change: Lwjgl3Window.deiconify() renamed to .restore() since it can also be used to de-maximize a window.
- Lwjgl3Window now has a maximize() method, and windows can be started maximized using the window or app configuration's setMaximized() method.
- NinePatch can now be drawn rotated or scaled.
- NinepatchDrawable is now a TransformDrawable.
- API Change: Group add* methods no longer remove and re-add the actor if it is already in the group, instead they do nothing.
- API Change: g2d.Animation is now generic so it can support Drawables, PolygonRegions, NinePatches, etc. To fix existing code, specify the TextureRegion type in animation declarations (and instantiations in Java 6), i.e. Animation myAnimation = new Animation(...);
- TiledDrawable throws unsupported operation if trying to draw rotated/scaled. #4005
- API Change: DragAndDrop now puts default position of drag actor at pointer location. The original default offset from the pointer was (14, -20).
- Added ShaderProgramLoader for AssetManager.
- BoundingBox#isValid now returns also true when min==max, see: https://github.com/libgdx/libgdx/pull/4460

If you use MobiDevelop’s RoboVM fork make sure to update your Eclipse/IntelliJ IDEA/Android Studio plugin. It works with iOS 10 devices, but does not work with the Xcode 8 beta just yet.

In other news, Multi-OS Engine has been open-sourced by Intel. It’s now being maintained by its originator, Migeran, who previously sold the IP to Intel. We will update to the OSS version in the coming week(s) and do another release.