class MAGES::Interaction::UI::MAGESGraphicRaycaster¶
Overview¶
A graphic raycaster for use with MAGES. It works for Pointer events and TrackedDevice events. More…
class MAGESGraphicRaycaster: public BaseRaycaster { public: // enums enum TrackedDeviceInteractionMode; // structs struct RaycastHitData; struct Sphere; // properties bool IgnoreReversedGraphics; bool CheckFor2DOcclusion; bool CheckFor3DOcclusion; LayerMask BlockingMask; TrackedDeviceInteractionMode TrackedDeviceInteraction; override int sortOrderPriority; override int renderOrderPriority; override Camera eventCamera; // methods override void Raycast( PointerEventData eventData, ListresultAppendList ); };
Detailed Documentation¶
A graphic raycaster for use with MAGES. It works for Pointer events and TrackedDevice events.
Partially created from fusing GraphicsRaycaster and TrackedDeviceRaycaster.
Properties¶
bool IgnoreReversedGraphics
Gets or sets a value indicating whether Graphics facing away from the raycaster are checked for raycasts.
bool CheckFor2DOcclusion
Gets or sets a value indicating whether to check for 2D occlusion.
bool CheckFor3DOcclusion
Gets or sets a value indicating whether to check for 3D occlusion.
LayerMask BlockingMask
Gets or sets the type of objects specified through LayerMask that are checked to determine if they block graphic raycasts.
TrackedDeviceInteractionMode TrackedDeviceInteraction
Gets or sets the tracked device interaction mode.
override int sortOrderPriority
Gets the priority of the raycaster based upon sort order.
Returns:
The sortOrder priority.
override int renderOrderPriority
Gets the priority of the raycaster based upon render order.
Returns:
The renderOrder priority.
override Camera eventCamera
Gets the camera that will generate rays for this raycaster.
Returns:
Null if Camera mode is ScreenSpaceOverlay or ScreenSpaceCamera and has no camera.
canvas.worldCanvas if not null
Camera.main
Hub.Instance.Rig.GetComponentInChildren<Camera>().
Methods¶
override void Raycast( PointerEventData eventData, ListresultAppendList )
Perform the raycast against the list of graphics associated with the Canvas.
Parameters:
eventData |
Current event data |
resultAppendList |
List of hit objects to append new results to. |