RaycastResult (interface)

This interface enables to abstract the content of a queried object for raycast queries, enabling for specialization of its content (eg: polygons, geometries).

注釈

The RaycastResult object must properly support the ‘clone’ operation

RaycastResult RaycastResult RaycastResult LinesRaycastResult LinesRaycastResult LinesRaycastResult->RaycastResult MeshRaycastResult MeshRaycastResult MeshRaycastResult->RaycastResult PointsRaycastResult PointsRaycastResult PointsRaycastResult->RaycastResult _GeometryInstancesRaycastResult _GeometryInstancesRaycastResult _GeometryInstancesRaycastResult->RaycastResult

Functions

Boolean compareAndUpdate ! ( in Size objectIndex, out Scalar maxDistance )
  copyResultFrom ! ( in Ref<RaycastResult> other )
  reset ! ( in Vec3 start, in Vec3 unitDir, in Boolean doubleSided, in Scalar coneThreshold )

Functions in detail

Boolean RaycastResult.compareAndUpdate! ( in Size objectIndex, out Scalar maxDistance )

If the raycast resulting distance is <= maxDistance, returns ‘true’ and the object should preserve location information for that best candidate.


RaycastResult.copyResultFrom! ( in Ref<RaycastResult> other )

Sets the resulting raycast location from the other RaycastResult (same type)


RaycastResult.reset! ( in Vec3 start, in Vec3 unitDir, in Boolean doubleSided, in Scalar coneThreshold )

Resets the content of the query (new raycast beginning)