MiscFunctions..::..IsPointInsidePolygon Method

Determines if a point is inside a polygon, where a polygon is an ordered list of 2D points. And the polygon is not self-intersecting

Namespace:  TVGL
Assembly:  TessellationAndVoxelizationGeometryLibraryUniversal (in TessellationAndVoxelizationGeometryLibraryUniversal.dll)

Syntax


public static bool IsPointInsidePolygon(
	List<Point> points,
	Point pointInQuestion,
	bool onBoundaryIsInside
)
Public Shared Function IsPointInsidePolygon ( _
	points As List(Of Point), _
	pointInQuestion As Point, _
	onBoundaryIsInside As Boolean _
) As Boolean
public:
static bool^ IsPointInsidePolygon(
	List<Point^>^ points, 
	Point^ pointInQuestion, 
	bool^ onBoundaryIsInside
)

Parameters

points
Type: List<(Of <(<'Point>)>)>
The points.
pointInQuestion
Type: TVGL..::..Point
The point in question.
onBoundaryIsInside
Type: Boolean
if set to true [on boundary is inside].

Return Value

true if [is point inside polygon] [the specified points]; otherwise, false.

Exceptions


ExceptionCondition
ExceptionFailed to return intercept information