Major VR GUI System Update

jMonkeyVR GUI’s system is now far more robust & faster. If your GUI looks good in non-VR, it will look identical now in VR mode. For example:

What happened before: individual GUI elements were placed into 3D space infront of the viewer, which caused all sorts of problems when things were not Z ordered correctly.

What happens now: The GUI is rendered just like it would be without VR, once, to a texture. Then, that texture is rendered on a “quad” infront of the player. This also means all the individual GUI elements only get rendered once!

This also means it might be easy to some really cool things, like render the GUI to a curved surface infront of the player.

Some changes had to be made to the code – for example, there is no more “VRGuiNode”, because it isn’t needed. You put elements on the guiNode with normal nodes, just as in non-VR mode. The new VRGuiManager automatically handles everything for you, although you can still set things like VRGuiManager.setGuiDistance(…).

See here for updated example code (which you notice looks so similar to non-VR code):

(Yes, this is a VR screenshot of my upcoming game, 5089. Yes, I still need to make some changes to make it more VR friendly).


Nice work @phr00t, these updates make me want to get a VR devkit :smiley: