Navigation
API > API/Runtime > API/Runtime/Core > API/Runtime/Core/Math > API/Runtime/Core/Math/FMath
References
Module | Core |
Header | /Engine/Source/Runtime/Core/Public/Math/UnrealMathUtility.h |
Include | #include "Math/UnrealMathUtility.h" |
Source | /Engine/Source/Runtime/Core/Private/Math/UnrealMath.cpp |
static bool GetDistanceWithinConeSegment
&40;
FVector Point,
FVector ConeStartPoint,
FVector ConeLine,
float RadiusAtStart,
float RadiusAtEnd,
float & PercentageOut
&41;
Remarks
Calculates whether a Point is within a cone segment, and also what percentage within the cone (100% is along the center line, whereas 0% is along the edge) true if the point is within the cone, false otherwise.
Parameters
Name | Description |
---|---|
Point | The Point in question |
ConeStartPoint | the beginning of the cone (with the smallest radius) |
ConeLine | the line out from the start point that ends at the largest radius point of the cone |
RadiusAtStart | the radius at the ConeStartPoint (0 for a 'proper' cone) |
RadiusAtEnd | the largest radius of the cone |
PercentageOut | output variable the holds how much within the cone the point is (1 = on center line, 0 = on exact edge or outside cone). |