Navigation
API > API/Runtime > API/Runtime/GeometryCore > API/Runtime/GeometryCore/Intersection
References
| Module | GeometryCore |
| Header | /Engine/Source/Runtime/GeometryCore/Public/Intersection/IntrSegment2Segment2.h |
| Include | #include "Intersection/IntrSegment2Segment2.h" |
Syntax
template<typename RealType>
class TIntrSegment2Segment2
Remarks
Ported from WildMagic5
RealType IntervalThreshold The intersection testing uses the center-extent form for line segments. If you start with endpoints (Vector2
RealType DotThreshold The computation for determining whether the linear components are parallel might contain small floating-point round-off errors. The default threshold is TMathUtil
The intersection set: Let q = Quantity. The cases are
q = 0: The segments do not intersect. Type is Empty
q = 1: The segments intersect in a single point. Type is Point Intersection point is Point0.
q = 2: The segments are collinear and intersect in a segment. Type is Segment. Points are Point0 and Point1 Calculate intersection between two 2D line segments
Variables
| Type | Name | Description | |
|---|---|---|---|
| RealType | DotThreshold | ||
| RealType | IntervalThreshold | ||
| RealType | Parameter0 | ||
| RealType | Parameter1 | ||
| TVector2< RealType > | Point0 | These values are all on segment 1, unlike many other tests!! | |
| TVector2< RealType > | Point1 | ||
| int | Quantity | Outputs | |
| EIntersectionResult | Result | ||
| TSegment2< RealType > | Segment1 | Inputs | |
| TSegment2< RealType > | Segment2 | ||
| EIntersectionType | Type |
Constructors
| Type | Name | Description | |
|---|---|---|---|
TIntrSegment2Segment2
(
const TSegment2< RealType >& Segment1In, |
Functions
| Type | Name | Description | |
|---|---|---|---|
| TIntrSegment2Segment2 & | Compute () |
||
| bool | Find () |
Note: This implementation is identical to TSegment2::Intersects but also computes the intersection geometry. | |
| RealType | |||
| RealType | |||
| const TSegment2< RealType > & | GetSegment1 () |
||
| const TSegment2< RealType > & | GetSegment2 () |
||
| bool | |||
| void | SanityCheck () |
||
| void | SetDotThreshold
(
RealType Value |
||
| void | SetIntervalThreshold
(
RealType Value |
||
| void | SetSegment1
(
const TSegment2< RealType >& Value |
||
| void | SetSegment2
(
const TSegment2< RealType >& Value |