Method CollidesWith
- Namespace
- GeometryHelper.Core
- Assembly
- GeometryHelper.dll
CollidesWith(GeoEllipse2, GeoLine2)
Determines whether an ellipse touches a segment, using the default tolerance.
public static bool CollidesWith(GeoEllipse2 ellipse, GeoLine2 line)
Parameters
ellipseGeoEllipse2lineGeoLine2
Returns
CollidesWith(GeoEllipse2, GeoLine2, Tolerance)
Determines whether an ellipse touches a segment, within a tolerance.
public static bool CollidesWith(GeoEllipse2 ellipse, GeoLine2 line, Tolerance tolerance)
Parameters
ellipseGeoEllipse2The ellipse.
lineGeoLine2The segment.
toleranceToleranceThe tolerance.
Returns
- bool
true if the segment comes within the point tolerance of the region, crossing the rim or lying inside; otherwise, false.
CollidesWith(GeoEllipse2, GeoPolyline2)
Determines whether an ellipse touches a polyline, using the default tolerance.
public static bool CollidesWith(GeoEllipse2 ellipse, GeoPolyline2 polyline)
Parameters
ellipseGeoEllipse2polylineGeoPolyline2
Returns
Exceptions
- ArgumentNullException
Thrown when the polyline is null.
CollidesWith(GeoEllipse2, GeoPolyline2, Tolerance)
Determines whether an ellipse touches a polyline, within a tolerance.
public static bool CollidesWith(GeoEllipse2 ellipse, GeoPolyline2 polyline, Tolerance tolerance)
Parameters
ellipseGeoEllipse2The ellipse.
polylineGeoPolyline2The polyline.
toleranceToleranceThe tolerance.
Returns
- bool
true if any edge comes within the point tolerance of the region; otherwise, false.
Exceptions
- ArgumentNullException
Thrown when the polyline is null.
CollidesWith(GeoEllipse2, GeoPolygon2)
Determines whether an ellipse touches or overlaps a polygon, using the default tolerance.
public static bool CollidesWith(GeoEllipse2 ellipse, GeoPolygon2 polygon)
Parameters
ellipseGeoEllipse2polygonGeoPolygon2
Returns
Exceptions
- ArgumentNullException
Thrown when the polygon is null.
CollidesWith(GeoEllipse2, GeoPolygon2, Tolerance)
Determines whether an ellipse touches or overlaps a polygon, within a tolerance.
public static bool CollidesWith(GeoEllipse2 ellipse, GeoPolygon2 polygon, Tolerance tolerance)
Parameters
ellipseGeoEllipse2The ellipse.
polygonGeoPolygon2The polygon.
toleranceToleranceThe tolerance.
Returns
- bool
true if the polygon holds the centre, or an edge comes within the point tolerance of the region; otherwise, false.
Exceptions
- ArgumentNullException
Thrown when the polygon is null.
CollidesWith(GeoEllipse2, GeoRectangle2)
Determines whether an ellipse touches or overlaps a rectangle, using the default tolerance.
public static bool CollidesWith(GeoEllipse2 ellipse, GeoRectangle2 rect)
Parameters
ellipseGeoEllipse2rectGeoRectangle2
Returns
CollidesWith(GeoEllipse2, GeoRectangle2, Tolerance)
Determines whether an ellipse touches or overlaps a rectangle, within a tolerance.
public static bool CollidesWith(GeoEllipse2 ellipse, GeoRectangle2 rect, Tolerance tolerance)
Parameters
ellipseGeoEllipse2The ellipse.
rectGeoRectangle2The rectangle.
toleranceToleranceThe tolerance.
Returns
- bool
true if the rectangle holds the centre, or a side comes within the point tolerance of the region; otherwise, false.
CollidesWith(GeoEllipse2, GeoTriangle2)
Determines whether an ellipse touches or overlaps a triangle, using the default tolerance.
public static bool CollidesWith(GeoEllipse2 ellipse, GeoTriangle2 triangle)
Parameters
ellipseGeoEllipse2triangleGeoTriangle2
Returns
CollidesWith(GeoEllipse2, GeoTriangle2, Tolerance)
Determines whether an ellipse touches or overlaps a triangle, within a tolerance.
public static bool CollidesWith(GeoEllipse2 ellipse, GeoTriangle2 triangle, Tolerance tolerance)
Parameters
ellipseGeoEllipse2The ellipse.
triangleGeoTriangle2The triangle; one whose corners coincide exactly is read as its longest edge, a short side being the side it is.
toleranceToleranceThe tolerance.
Returns
- bool
true if the two come within the point tolerance of each other; otherwise, false.
CollidesWith(GeoEllipse2, GeoFace2)
Determines whether an ellipse reaches the material of a face, using the default tolerance.
public static bool CollidesWith(GeoEllipse2 ellipse, GeoFace2 face)
Parameters
ellipseGeoEllipse2faceGeoFace2
Returns
Exceptions
- ArgumentNullException
Thrown when the face is null.
CollidesWith(GeoEllipse2, GeoFace2, Tolerance)
Determines whether an ellipse reaches the material of a face, within a tolerance.
public static bool CollidesWith(GeoEllipse2 ellipse, GeoFace2 face, Tolerance tolerance)
Parameters
ellipseGeoEllipse2The ellipse.
faceGeoFace2The face: its outline, less its holes.
toleranceToleranceThe tolerance.
Returns
- bool
true if the ellipse comes within the point tolerance of the material, as DistanceTo(GeoEllipse2, GeoFace2, Tolerance) says; otherwise, false.
Remarks
An ellipse wholly inside a hole, or holding it within itself, is told apart from one reaching the material by the exact distance to the rims, so a collision and a distance never disagree. A rim edge whose box lies outside the ellipse's own axis-aligned box, widened by the point tolerance, cannot be within it and is not measured, and the search stops at the first edge within the point tolerance: the answer is the same as the distance's, found sooner.
Exceptions
- ArgumentNullException
Thrown when the face is null.
CollidesWith(GeoEllipse2, GeoEdge2)
Determines whether an ellipse touches an edge, using the default tolerance.
public static bool CollidesWith(GeoEllipse2 ellipse, GeoEdge2 edge)
Parameters
ellipseGeoEllipse2edgeGeoEdge2
Returns
CollidesWith(GeoEllipse2, GeoEdge2, Tolerance)
Determines whether an ellipse touches an edge, within a tolerance: as a segment or as an arc, whichever the edge is.
public static bool CollidesWith(GeoEllipse2 ellipse, GeoEdge2 edge, Tolerance tolerance)
Parameters
ellipseGeoEllipse2edgeGeoEdge2toleranceTolerance
Returns
CollidesWith(GeoEllipse2, GeoCircle2)
Determines whether an ellipse touches or overlaps a circle, using the default tolerance.
public static bool CollidesWith(GeoEllipse2 ellipse, GeoCircle2 circle)
Parameters
ellipseGeoEllipse2circleGeoCircle2
Returns
CollidesWith(GeoEllipse2, GeoCircle2, Tolerance)
Determines whether an ellipse touches or overlaps a circle, within a tolerance.
public static bool CollidesWith(GeoEllipse2 ellipse, GeoCircle2 circle, Tolerance tolerance)
Parameters
ellipseGeoEllipse2The ellipse.
circleGeoCircle2The circle.
toleranceToleranceThe tolerance.
Returns
- bool
true if the two come within the point tolerance of each other, one inside the other included; otherwise, false.
CollidesWith(GeoEllipse2, GeoArc2)
Determines whether an ellipse touches an arc, using the default tolerance.
public static bool CollidesWith(GeoEllipse2 ellipse, GeoArc2 arc)
Parameters
ellipseGeoEllipse2arcGeoArc2
Returns
CollidesWith(GeoEllipse2, GeoArc2, Tolerance)
Determines whether an ellipse touches an arc, within a tolerance.
public static bool CollidesWith(GeoEllipse2 ellipse, GeoArc2 arc, Tolerance tolerance)
Parameters
ellipseGeoEllipse2The ellipse.
arcGeoArc2The arc.
toleranceToleranceThe tolerance.
Returns
- bool
true if the arc comes within the point tolerance of the region, crossing the rim or lying inside; otherwise, false.
CollidesWith(GeoEllipse2, GeoEllipse2)
Determines whether two ellipses touch or overlap, using the default tolerance.
public static bool CollidesWith(GeoEllipse2 ellipse, GeoEllipse2 other)
Parameters
ellipseGeoEllipse2otherGeoEllipse2
Returns
CollidesWith(GeoEllipse2, GeoEllipse2, Tolerance)
Determines whether two ellipses touch or overlap, within a tolerance.
public static bool CollidesWith(GeoEllipse2 ellipse, GeoEllipse2 other, Tolerance tolerance)
Parameters
ellipseGeoEllipse2The first ellipse.
otherGeoEllipse2The second ellipse.
toleranceToleranceThe tolerance.
Returns
- bool
true if the two come within the point tolerance of each other, one inside the other included; otherwise, false.
CollidesWith(GeoEllipse2, GeoPolylineArc2)
Determines whether an ellipse touches a curved chain, using the default tolerance.
public static bool CollidesWith(GeoEllipse2 ellipse, GeoPolylineArc2 chain)
Parameters
ellipseGeoEllipse2chainGeoPolylineArc2
Returns
Exceptions
- ArgumentNullException
Thrown when the chain is null.
CollidesWith(GeoEllipse2, GeoPolylineArc2, Tolerance)
Determines whether an ellipse touches a curved chain, within a tolerance.
public static bool CollidesWith(GeoEllipse2 ellipse, GeoPolylineArc2 chain, Tolerance tolerance)
Parameters
ellipseGeoEllipse2The ellipse.
chainGeoPolylineArc2The chain.
toleranceToleranceThe tolerance.
Returns
- bool
true if any edge comes within the point tolerance of the region; otherwise, false.
Exceptions
- ArgumentNullException
Thrown when the chain is null.
CollidesWith(GeoEllipse2, GeoPolygonArc2)
Determines whether an ellipse touches or overlaps a curved loop, using the default tolerance.
public static bool CollidesWith(GeoEllipse2 ellipse, GeoPolygonArc2 loop)
Parameters
ellipseGeoEllipse2loopGeoPolygonArc2
Returns
Exceptions
- ArgumentNullException
Thrown when the loop is null.
CollidesWith(GeoEllipse2, GeoPolygonArc2, Tolerance)
Determines whether an ellipse touches or overlaps a curved loop, within a tolerance.
public static bool CollidesWith(GeoEllipse2 ellipse, GeoPolygonArc2 loop, Tolerance tolerance)
Parameters
ellipseGeoEllipse2The ellipse.
loopGeoPolygonArc2The loop.
toleranceToleranceThe tolerance.
Returns
- bool
true if the loop holds the centre, or an edge comes within the point tolerance of the region; otherwise, false.
Exceptions
- ArgumentNullException
Thrown when the loop is null.
CollidesWith(GeoEllipse2, GeoRay2)
Determines whether an ellipse touches a ray, using the default tolerance.
public static bool CollidesWith(GeoEllipse2 ellipse, GeoRay2 ray)
Parameters
ellipseGeoEllipse2rayGeoRay2
Returns
CollidesWith(GeoEllipse2, GeoRay2, Tolerance)
Determines whether an ellipse touches a ray, within a tolerance.
public static bool CollidesWith(GeoEllipse2 ellipse, GeoRay2 ray, Tolerance tolerance)
Parameters
ellipseGeoEllipse2The ellipse.
rayGeoRay2The ray.
toleranceToleranceThe tolerance.
Returns
- bool
true if the ray comes within the point tolerance of the region, crossing the rim or starting inside; otherwise, false.