Table of Contents

Class Distance3

Namespace
GeometryHelper.Core
Assembly
GeometryHelper.dll

Provides static methods for distance calculations in 3D space.

Every distance here is the shortest gap between the two shapes, and is zero when they touch or overlap. A bounded shape is measured as the set of points it actually occupies: a segment ends at its endpoints, a triangle includes its interior, and a plane is infinite in every direction.

public static class Distance3
Inheritance
Distance3
Inherited Members

Remarks

A chain could be measured to a point and to nothing else, which left the way out of a curved chain leading nowhere: ToPolyline3(double) hands back a straight chain following the arcs as closely as asked, and there was then nothing to ask it. These are the pairs that close that gap, and every one of them is exact for the straight chain it is given.

So the way to measure a bent bar against anything is to say how closely it should be followed and then ask the ordinary question: bar.ToPolyline3(0.1).DistanceTo(slab). The accuracy sits in the call where it can be seen, which is the same bargain GeoCircle3 offers.

Methods

DistanceTo(GeoAabb3, GeoAabb3)

Calculates the shortest distance between two axis-aligned boxes.

DistanceTo(GeoAabb3, GeoPoint3)

Calculates the perpendicular distance from an axis-aligned box to a point.

DistanceTo(GeoCircle3, GeoPoint3)

Calculates the shortest distance from a circular disc to a point.

DistanceTo(GeoCircle3, GeoPoint3, Tolerance)

Calculates the shortest distance from a circular disc to a point, within a tolerance.

DistanceTo(GeoFace3, GeoAabb3)

Calculates the shortest distance between the material of a face and an axis-aligned box.

DistanceTo(GeoFace3, GeoAabb3, Tolerance)

Calculates the shortest distance between the material of a face and an axis-aligned box, within a tolerance: the answer of DistanceTo(GeoSolid3, GeoFace3, Tolerance) for ToObb().ToSolid().

DistanceTo(GeoFace3, GeoFace3)

Calculates the shortest distance between the materials of two faces.

DistanceTo(GeoFace3, GeoFace3, Tolerance)

Calculates the shortest distance between the materials of two faces, within a tolerance.

DistanceTo(GeoFace3, GeoObb3)

Calculates the shortest distance between the material of a face and an oriented box.

DistanceTo(GeoFace3, GeoObb3, Tolerance)

Calculates the shortest distance between the material of a face and an oriented box, within a tolerance: the answer of DistanceTo(GeoSolid3, GeoFace3, Tolerance) for ToSolid().

DistanceTo(GeoFace3, GeoPoint3)

Calculates the shortest distance from a face to a point.

DistanceTo(GeoFace3, GeoPoint3, Tolerance)

Calculates the shortest distance from a face to a point, within a tolerance.

DistanceTo(GeoFace3, GeoPolygon3)

Calculates the shortest distance between the material of a face and a polygon.

DistanceTo(GeoFace3, GeoPolygon3, Tolerance)

Calculates the shortest distance between the material of a face and a polygon, within a tolerance.

DistanceTo(GeoLine3, GeoAabb3)

Calculates the shortest distance between a line segment and an axis-aligned box.

DistanceTo(GeoLine3, GeoAabb3, Tolerance)

Calculates the shortest distance between a line segment and an axis-aligned box, within a tolerance: the answer of DistanceTo(GeoLine3, GeoSolid3, Tolerance) for ToObb().ToSolid().

DistanceTo(GeoLine3, GeoFace3)

Calculates the shortest distance between a line segment and the material of a face.

DistanceTo(GeoLine3, GeoFace3, Tolerance)

Calculates the shortest distance between a line segment and the material of a face, within a tolerance.

DistanceTo(GeoLine3, GeoLine3)

Calculates the shortest distance between two line segments.

DistanceTo(GeoLine3, GeoLine3, Tolerance)

Calculates the shortest distance between two line segments, within a tolerance.

DistanceTo(GeoLine3, GeoObb3)

Calculates the shortest distance between a line segment and an oriented box.

DistanceTo(GeoLine3, GeoObb3, Tolerance)

Calculates the shortest distance between a line segment and an oriented box, within a tolerance: the answer of DistanceTo(GeoLine3, GeoSolid3, Tolerance) for ToSolid().

DistanceTo(GeoLine3, GeoPoint3)

Calculates the shortest distance from a line segment to a point.

DistanceTo(GeoLine3, GeoPoint3, Tolerance)

Calculates the shortest distance from a line segment to a point, within a tolerance.

DistanceTo(GeoLine3, GeoPolygon3)

Calculates the shortest distance between a line segment and a polygon.

DistanceTo(GeoLine3, GeoPolygon3, Tolerance)

Calculates the shortest distance between a line segment and a polygon, within a tolerance.

DistanceTo(GeoLine3, GeoSolid3)

Calculates the shortest distance between a line segment and a solid.

DistanceTo(GeoLine3, GeoSolid3, Tolerance)

Calculates the shortest distance between a line segment and a solid. A segment reaching into the body is at distance zero.

DistanceTo(GeoLine3, GeoTriangle3)

Calculates the shortest distance between a line segment and a triangle.

DistanceTo(GeoLine3, GeoTriangle3, Tolerance)

Calculates the shortest distance between a line segment and a triangle, within a tolerance.

DistanceTo(GeoObb3, GeoAabb3)

Calculates the shortest distance between an oriented box and an axis-aligned box.

DistanceTo(GeoObb3, GeoAabb3, Tolerance)

Calculates the shortest distance between an oriented box and an axis-aligned box, within a tolerance: the answer of DistanceTo(GeoObb3, GeoObb3, Tolerance) for box2.ToObb(), two oriented boxes being measured as their bodies once the separating axis test has found them apart.

DistanceTo(GeoObb3, GeoObb3)

Calculates the shortest distance between two oriented boxes.

DistanceTo(GeoObb3, GeoObb3, Tolerance)

Calculates the shortest distance between two oriented boxes, within a tolerance.

DistanceTo(GeoObb3, GeoPoint3)

Calculates the shortest distance from an oriented box to a point. A point inside the box is at distance zero.

DistanceTo(GeoPlane3, GeoAabb3)

Calculates the shortest distance between a plane and an axis-aligned box.

DistanceTo(GeoPlane3, GeoAabb3, Tolerance)

Calculates the shortest distance between a plane and an axis-aligned box, within a tolerance: the answer of DistanceTo(GeoSolid3, GeoPlane3, Tolerance) for ToObb().ToSolid().

DistanceTo(GeoPlane3, GeoFace3)

Calculates the shortest distance between a plane and the material of a face.

DistanceTo(GeoPlane3, GeoFace3, Tolerance)

Calculates the shortest distance between a plane and the material of a face, within a tolerance.

DistanceTo(GeoPlane3, GeoLine3)

Calculates the shortest distance from a plane to a line segment.

DistanceTo(GeoPlane3, GeoObb3)

Calculates the shortest distance between a plane and an oriented box.

DistanceTo(GeoPlane3, GeoObb3, Tolerance)

Calculates the shortest distance between a plane and an oriented box, within a tolerance: the answer of DistanceTo(GeoSolid3, GeoPlane3, Tolerance) for ToSolid().

DistanceTo(GeoPlane3, GeoPlane3)

Calculates the distance between two planes.

DistanceTo(GeoPlane3, GeoPlane3, Tolerance)

Calculates the distance between two planes, within a tolerance.

DistanceTo(GeoPlane3, GeoPoint3)

Calculates the perpendicular distance from a plane to a point.

DistanceTo(GeoPlane3, GeoPolygon3)

Calculates the shortest distance between a plane and a polygon.

DistanceTo(GeoPlane3, GeoPolygon3, Tolerance)

Calculates the shortest distance between a plane and a polygon, within a tolerance.

DistanceTo(GeoPlane3, GeoTriangle3)

Calculates the shortest distance between a plane and a triangle.

DistanceTo(GeoPlane3, GeoTriangle3, Tolerance)

Calculates the shortest distance between a plane and a triangle, within a tolerance.

DistanceTo(GeoPoint3, GeoPoint3)

Calculates the distance between two points.

DistanceTo(GeoPolygon3, GeoAabb3)

Calculates the shortest distance between a polygon and an axis-aligned box.

DistanceTo(GeoPolygon3, GeoAabb3, Tolerance)

Calculates the shortest distance between a polygon and an axis-aligned box, within a tolerance: the answer of DistanceTo(GeoSolid3, GeoPolygon3, Tolerance) for ToObb().ToSolid().

DistanceTo(GeoPolygon3, GeoObb3)

Calculates the shortest distance between a polygon and an oriented box.

DistanceTo(GeoPolygon3, GeoObb3, Tolerance)

Calculates the shortest distance between a polygon and an oriented box, within a tolerance: the answer of DistanceTo(GeoSolid3, GeoPolygon3, Tolerance) for ToSolid().

DistanceTo(GeoPolygon3, GeoPoint3)

Calculates the shortest distance from a polygon to a point.

DistanceTo(GeoPolygon3, GeoPoint3, Tolerance)

Calculates the shortest distance from a polygon to a point, within a tolerance.

DistanceTo(GeoPolygon3, GeoPolygon3)

Calculates the shortest distance between two polygons.

DistanceTo(GeoPolygon3, GeoPolygon3, Tolerance)

Calculates the shortest distance between two polygons, within a tolerance.

DistanceTo(GeoPolyline3, GeoAabb3)

Calculates the shortest distance between a chain and an axis-aligned box.

DistanceTo(GeoPolyline3, GeoAabb3, Tolerance)

Calculates the shortest distance between a chain and an axis-aligned box, within a tolerance.

DistanceTo(GeoPolyline3, GeoFace3)

Calculates the shortest distance between a chain and the material of a face.

DistanceTo(GeoPolyline3, GeoFace3, Tolerance)

Calculates the shortest distance between a chain and the material of a face, within a tolerance.

DistanceTo(GeoPolyline3, GeoLine3)

Calculates the shortest distance between a chain and a line segment.

DistanceTo(GeoPolyline3, GeoLine3, Tolerance)

Calculates the shortest distance between a chain and a line segment, within a tolerance: nought only where they truly meet, otherwise the gap, measured exactly, each side of the chain the side it is. A segment no longer than the tolerance is read as its start where it does not truly meet the chain.

DistanceTo(GeoPolyline3, GeoObb3)

Calculates the shortest distance between a chain and an oriented box.

DistanceTo(GeoPolyline3, GeoObb3, Tolerance)

Calculates the shortest distance between a chain and an oriented box, within a tolerance.

DistanceTo(GeoPolyline3, GeoPlane3)

Calculates the shortest distance between a chain and a plane.

DistanceTo(GeoPolyline3, GeoPlane3, Tolerance)

Calculates the shortest distance between a chain and a plane, within a tolerance.

DistanceTo(GeoPolyline3, GeoPoint3)

Calculates the shortest distance from a polyline to a point.

DistanceTo(GeoPolyline3, GeoPoint3, Tolerance)

Calculates the shortest distance from a polyline to a point, within a tolerance.

DistanceTo(GeoPolyline3, GeoPolygon3)

Calculates the shortest distance between a chain and a polygon.

DistanceTo(GeoPolyline3, GeoPolygon3, Tolerance)

Calculates the shortest distance between a chain and a polygon, within a tolerance: nought only where an edge truly meets the polygon, otherwise the gap, measured exactly.

DistanceTo(GeoPolyline3, GeoPolyline3)

Calculates the shortest distance between two chains.

DistanceTo(GeoPolyline3, GeoPolyline3, Tolerance)

Calculates the shortest distance between two chains, within a tolerance: nought only where they truly meet, otherwise the gap, measured exactly and the same whichever is asked first, each side the side it is.

DistanceTo(GeoPolyline3, GeoRay3)

Calculates the shortest distance between a chain and a ray.

DistanceTo(GeoPolyline3, GeoRay3, Tolerance)

Calculates the shortest distance between a chain and a ray, within a tolerance.

DistanceTo(GeoPolyline3, GeoTriangle3)

Calculates the shortest distance between a chain and a triangle.

DistanceTo(GeoPolyline3, GeoTriangle3, Tolerance)

Calculates the shortest distance between a chain and a triangle, within a tolerance: nought only where one of its segments truly meets the triangle, otherwise the gap, measured exactly.

DistanceTo(GeoRay3, GeoAabb3)

Calculates the shortest distance between a ray and an axis-aligned box.

DistanceTo(GeoRay3, GeoAabb3, Tolerance)

Calculates the shortest distance between a ray and an axis-aligned box, within a tolerance: the answer of DistanceTo(GeoRay3, GeoSolid3, Tolerance) for ToObb().ToSolid().

DistanceTo(GeoRay3, GeoFace3)

Calculates the shortest distance between a ray and the material of a face.

DistanceTo(GeoRay3, GeoFace3, Tolerance)

Calculates the shortest distance between a ray and the material of a face, within a tolerance.

DistanceTo(GeoRay3, GeoLine3)

Calculates the shortest distance between a ray and a line segment.

DistanceTo(GeoRay3, GeoLine3, Tolerance)

Calculates the shortest distance between a ray and a line segment, within a tolerance.

DistanceTo(GeoRay3, GeoObb3)

Calculates the shortest distance between a ray and an oriented box.

DistanceTo(GeoRay3, GeoObb3, Tolerance)

Calculates the shortest distance between a ray and an oriented box, within a tolerance: the answer of DistanceTo(GeoRay3, GeoSolid3, Tolerance) for ToSolid().

DistanceTo(GeoRay3, GeoPlane3)

Calculates the shortest distance between a ray and a plane.

DistanceTo(GeoRay3, GeoPlane3, Tolerance)

Calculates the shortest distance between a ray and a plane, within a tolerance.

DistanceTo(GeoRay3, GeoPoint3)

Calculates the shortest distance from a ray to a point.

DistanceTo(GeoRay3, GeoPolygon3)

Calculates the shortest distance between a ray and a polygon.

DistanceTo(GeoRay3, GeoPolygon3, Tolerance)

Calculates the shortest distance between a ray and a polygon, within a tolerance.

DistanceTo(GeoRay3, GeoRay3)

Calculates the shortest distance between two rays.

DistanceTo(GeoRay3, GeoRay3, Tolerance)

Calculates the shortest distance between two rays, within a tolerance.

DistanceTo(GeoRay3, GeoSolid3)

Calculates the shortest distance between a ray and a solid.

DistanceTo(GeoRay3, GeoSolid3, Tolerance)

Calculates the shortest distance between a ray and a solid, within a tolerance.

DistanceTo(GeoRay3, GeoTriangle3)

Calculates the shortest distance between a ray and a triangle.

DistanceTo(GeoRay3, GeoTriangle3, Tolerance)

Calculates the shortest distance between a ray and a triangle, within a tolerance.

DistanceTo(GeoSolid3, GeoAabb3)

Calculates the shortest distance between a solid and an axis-aligned box.

DistanceTo(GeoSolid3, GeoAabb3, Tolerance)

Calculates the shortest distance between a solid and an axis-aligned box, within a tolerance.

DistanceTo(GeoSolid3, GeoFace3)

Calculates the shortest distance between a solid and the material of a face.

DistanceTo(GeoSolid3, GeoFace3, Tolerance)

Calculates the shortest distance between a solid and the material of a face, within a tolerance.

DistanceTo(GeoSolid3, GeoObb3)

Calculates the shortest distance between a solid and an oriented box.

DistanceTo(GeoSolid3, GeoObb3, Tolerance)

Calculates the shortest distance between a solid and an oriented box, within a tolerance.

DistanceTo(GeoSolid3, GeoPlane3)

Calculates the shortest distance between a solid and a plane.

DistanceTo(GeoSolid3, GeoPlane3, Tolerance)

Calculates the shortest distance between a solid and a plane, within a tolerance.

DistanceTo(GeoSolid3, GeoPoint3)

Calculates the shortest distance from a solid to a point. A point inside the solid is at distance zero.

DistanceTo(GeoSolid3, GeoPoint3, Tolerance)

Calculates the shortest distance from a solid to a point, within a tolerance.

DistanceTo(GeoSolid3, GeoPolygon3)

Calculates the shortest distance between a solid and a polygon.

DistanceTo(GeoSolid3, GeoPolygon3, Tolerance)

Calculates the shortest distance between a solid and a polygon, within a tolerance.

DistanceTo(GeoSolid3, GeoPolyline3)

Calculates the shortest distance between a solid and a polyline.

DistanceTo(GeoSolid3, GeoPolyline3, Tolerance)

Calculates the shortest distance between a solid and a polyline, within a tolerance.

DistanceTo(GeoSolid3, GeoSolid3)

Calculates the shortest distance between two solids.

DistanceTo(GeoSolid3, GeoSolid3, Tolerance)

Calculates the shortest distance between two solids, within a tolerance.

DistanceTo(GeoSolid3, GeoTriangle3)

Calculates the shortest distance between a solid and a triangle.

DistanceTo(GeoSolid3, GeoTriangle3, Tolerance)

Calculates the shortest distance between a solid and a triangle, within a tolerance.

DistanceTo(GeoTriangle3, GeoAabb3)

Calculates the shortest distance between a triangle and an axis-aligned box.

DistanceTo(GeoTriangle3, GeoAabb3, Tolerance)

Calculates the shortest distance between a triangle and an axis-aligned box, within a tolerance: the answer of DistanceTo(GeoSolid3, GeoTriangle3, Tolerance) for ToObb().ToSolid().

DistanceTo(GeoTriangle3, GeoFace3)

Calculates the shortest distance between a triangle and the material of a face.

DistanceTo(GeoTriangle3, GeoFace3, Tolerance)

Calculates the shortest distance between a triangle and the material of a face, within a tolerance.

DistanceTo(GeoTriangle3, GeoObb3)

Calculates the shortest distance between a triangle and an oriented box.

DistanceTo(GeoTriangle3, GeoObb3, Tolerance)

Calculates the shortest distance between a triangle and an oriented box, within a tolerance: the answer of DistanceTo(GeoSolid3, GeoTriangle3, Tolerance) for ToSolid().

DistanceTo(GeoTriangle3, GeoPoint3)

Calculates the shortest distance from a triangle to a point.

DistanceTo(GeoTriangle3, GeoPolygon3)

Calculates the shortest distance between a triangle and a polygon.

DistanceTo(GeoTriangle3, GeoPolygon3, Tolerance)

Calculates the shortest distance between a triangle and a polygon, within a tolerance.

DistanceTo(GeoTriangle3, GeoTriangle3)

Calculates the shortest distance between two triangles.

DistanceTo(GeoTriangle3, GeoTriangle3, Tolerance)

Calculates the shortest distance between two triangles, within a tolerance.

GetDistanceSquaredTo(GeoPoint3, GeoPoint3)

Calculates the squared distance between two points.

SignedDistanceTo(GeoAabb3, GeoPoint3)

Calculates the distance from an axis-aligned box to a point, negative for a point inside it.

SignedDistanceTo(GeoAabb3, GeoPoint3, Tolerance)

Calculates the distance from an axis-aligned box to a point, negative for a point inside it, within a tolerance.

SignedDistanceTo(GeoObb3, GeoPoint3)

Calculates the distance from an oriented box to a point, negative for a point inside it.

SignedDistanceTo(GeoObb3, GeoPoint3, Tolerance)

Calculates the distance from an oriented box to a point, negative for a point inside it, within a tolerance.

SignedDistanceTo(GeoSolid3, GeoPoint3)

Calculates the distance from a solid to a point, negative for a point inside the body.

SignedDistanceTo(GeoSolid3, GeoPoint3, Tolerance)

Calculates the distance from a solid to a point, negative for a point inside the body, within a tolerance.