World

Canvas UI

How to Add a Canvas

  • Add a canvas to the scene hierarchy and give it a suitable name.

BasisFramework UI canvas context window

Note: If you are making a World Space canvas, an X,Y,Z a scale of 0.001 is usually a good starting value.

  • Remove the Graphic Raycaster component if it is present. Basis provides its own graphics raycaster.

BasisFramework UI canvas remove graphic raycaster

  • Add a Basis Graphics UI Ray Caster component and attach your canvas object to its Canvas field in the inspector.

BasisFramework UI canvas add Basis Graphic Raycaster

  • Change the canvas layer to OverlayUI.

BasisFramework UI canvas layer OverlayUI

Ensure that there are no EventSystem objects in your scene, otherwise any UI items added to your canvas will not be able to be interacted with.

Below is an example image of a canvas containing a panel, toggle, button, dropdown, slider and input field.

BasisFramework UI canvas layer OverlayUI

Note: When looking at a UI item, your raycast pointer or cursor turns into a blue circle.