Click or drag to resize
Accord.NET (logo)

LineGetIntersectionWith Method (LineSegment)

Finds, provided it exists, the intersection point with the specified LineSegment.

Namespace:  Accord.Math.Geometry
Assembly:  Accord.Math (in Accord.Math.dll) Version: 3.8.0
Syntax
public Nullable<Point> GetIntersectionWith(
	LineSegment other
)
Request Example View Source

Parameters

other
Type: Accord.Math.GeometryLineSegment
LineSegment to find intersection with.

Return Value

Type: NullablePoint
Returns intersection point with the specified LineSegment, or , if this line does not intersect with the segment.
Exceptions
ExceptionCondition
InvalidOperationExceptionThrown if other is a portion of this line.
Remarks

If the line and segment do not intersect, the method returns . If the line and segment share multiple points, the method throws an InvalidOperationException.

See Also