FGeometrySet3::FindNearestPointToRay

PointWithinToleranceTest is called in parallel and hence must be thread-safe/re-entrant!

Choose your operating system:

Windows

macOS

Linux

Warnings

  • PointWithinToleranceTest is called in parallel and hence must be thread-safe/re-entrant!

References

Module

GeometryCore

Header

/Engine/Source/Runtime/GeometryCore/Public/Spatial/GeometrySet3.h

Include

#include "Spatial/GeometrySet3.h"

Source

/Engine/Source/Runtime/GeometryCore/Private/Spatial/GeometrySet3.cpp

Syntax

bool FindNearestPointToRay
(
    const FRay3d & Ray,
    FNearest & ResultOut,
    TFunction< bool &, const FVector3d &)> PointWithinToleranceTest
) const

Remarks

PointWithinToleranceTest is called in parallel and hence must be thread-safe/re-entrant!

Returns

true if the nearest point on Ray to some point in the set passed the PointWithinToleranceTest.

Parameters

Parameter

Description

Ray

query ray

ResultOut

populated with information about successful nearest point result

PointWithinToleranceTest

should return true if two 3D points are "close enough" to be considered a hit