Tilt Five GDExtension for Godot 4

TiltFiveGodot4 is GDExtension for the Godot 4 engine to connect to the Tilt Five system. It extends Godot's XRInterface and adds T5 Nodes to handle the creation of the XR rigs in the scene.

Platform Support

Renderer
Forward+
Renderer
Mobile
Renderer
Compatibility
Windows
Linux [1]
Android [2]

Installation

  • From this page Release Godot TiltFive 1.1.0 download either gdtiltfive_gdscript.zip or gdtiltfive_csharp.zipdepending on which scripting language you want to use.
  • Create a Godot project
  • In AssetLib tab select the Import... button.

    Pasted image 20231201105940.png
  • Select the zip file you downloaded and press Open
  • Be sure to check Ignore asset root and then click the Install button.

    ConfigureAssetBefireInstall.png
  • It is recommended that you save and reopen the project now.
  • Go to the Project->Project Settings... menu option and enable the Tilt Five plugin.

    godot-plugins-dialog.png
  • Also in project setting dialog enable the XR->Shaders option.

    XR-shaders-setting.png
  • It is recommended that you save and reopen the project at this point too.

The Quick Start Cube

  • Create a new 3D scene.
  • Add a Light and Environment
  • Open the Create New Node dialog. Type T5 in the search field. Select T5Manager and click the Create button.

    CreateNewNode.png
  • Next add a T5Gameboard node.
  • Click on The T5Manager in the scene tree and look at it's property inspector. Set the Start Location property to the T5Gameboard node you added.

    t5manager-inspector.png
  • Next click on The T5Gameboard in the scene tree and look at it's property inspector. Set the Content Scale property to 10.

    t5-gameboard-inspector.png
  • Finally add a MeshInstance3D and select the BoxMesh

Your scene tree should now look something like this.

t5-cube-scene.png

At this point you should be able to run the scene, put on your Tilt Five glasses and see the cube on the board.

About the Tilt Five Godot plugin

The XR rig

The plugin will create and manage the connection between the Tilt Five hardware and one or more XR rigs it will create in your root scene. An XR rig is just a regular Godot scene with a specific layout of required nodes that map to parts of the Tilt Five hardware. Where and how each XR rig is created is controlled by a T5Manager node in the root scene.

The default XR rig T5XRRig is found in res://addons/tiltfive/scenes/ folder of your project.

T5-XR-rig-mapping.png

The XR rig has the following required layout of

  • T5XRRig is a Godot SubViewport node at the root node of the hierarchy. This is the viewport that your world will be rendered to for the pair of glasses attached to this rig.
  • Origin is a T5Origin3D node that is a child of T5XRRig node. It maps the center of the Tilt Five gameboard to a location in world coordinates.
  • Camera is a T5Camera3D node that is a child of the T5Origin3D node. It will track the location of the users head relative to the origin.
  • Wand_1 is a T5Controller3D node that is also a child of the T5Origin3D node. It will track the location of the Tilt Five wand relative to the origin.

It's very likely that you will eventually want attach things like colliders, raycasters or custom scripts to the XR rig nodes for your particular Tilt Five application. You can do this by inheriting from T5XRRig.tcsn to get all the required nodes in the correct layout.

t5-glasses-inherited-scene.png

T5Manger

The main scene should have a T5Manager node. It is a basic manager that will create one XR rig for each pair of Tilt Five glasses that is connected to the computer. T5Manager has a couple of properties to customize it's behavior.

t5manager-inspector.png

  • Glasses Scene can be set to a custom XR rig to be used in place of the default T5XRRig.
  • Start Location can be set to a T5Gameboard node in the scene. The manager will use this to set the initial location and content scaling of the T5Origin3D in the XR rig it creates. If this field is blank the manager will set the 'T5Origin3D' to the world origin.

T5Gameboard

The T5Gameboard node is useful for visualizing the size of 3D content on the physical gameboard.

T5Gameboard.png
t5-gameboard-inspector.png

The gameboard has several properties.

  • Content Scale - The active area of an Tilt Five LE game board is 0.7m X 0.7m. Content scale maps this area into Godot units. A content scale of 1 means that Godot units match the physical units of the gameboard so it would map to a 0.7m X 0.7m area in Godot world coordinates. Setting content scale to 10 would map a 7m X 7m area.
  • Gameboard Type - This sets the type of gameboard visualized in the scene.
  • Show at Runtime - By default when the application is run the gameboard visualization will be hidden. However, when the application is setup to mirror the scene to the main display it might be desirable to visualize the gameboard in this view.
  • Layers - In support of Show at Runtime this can be set to change the layers the gameboard is rendered to.

When the T5Gameboard node is linked in the T5Manager the manager will use the location and content scale of the gameboard to set up the T5Origin3D node of the XR rig. This can be useful for setting player start locations.


  1. Alpha version available ↩︎
  2. Builds but JNI integration needs work ↩︎