Navigation
API > API/Plugins > API/Plugins/GeometryScriptingCore > API/Plugins/GeometryScriptingCore/GeometryScript > API/Plugins/GeometryScriptingCore/GeometryScript/UGeometryScriptL-_23
References
| Module | GeometryScriptingCore |
| Header | /Engine/Plugins/Experimental/GeometryScripting/Source/GeometryScriptingCore/Public/GeometryScript/MeshSpatialFunctions.h |
| Include | #include "GeometryScript/MeshSpatialFunctions.h" |
| Source | /Engine/Plugins/Experimental/GeometryScripting/Source/GeometryScriptingCore/Private/MeshSpatialFunctions.cpp |
static UDynamicMesh &42; FindNearestRayIntersectionWithMesh
&40;
UDynamicMesh &42; TargetMesh,
const FGeometryScriptDynamicMeshBVH & QueryBVH,
FVector RayOrigin,
FVector RayDirection,
FGeometryScriptSpatialQueryOptions Options,
FGeometryScriptRayHitResult & HitResult,
EGeometryScriptSearchOutcomePins & Outcome,
UGeometryScriptDebug &42; Debug
&41;
Remarks
Finds the nearest intersection of a 3D ray with the mesh by using the Query BVH. Note, depending on the Ray Origin and Ray Direction, there is the possibility that the ray might not intersect with the Target Mesh. Should the ray miss, the HitResult.bHit will be false and the Outcome will be Not Found.