Table of Contents

Method TryIntersect

Namespace
GeometryHelper.Core
Assembly
GeometryHelper.dll

TryIntersect(GeoSolid3, GeoSolid3, out GeoSolid3)

Gets the part two solids have in common, using the default tolerance.

public static bool TryIntersect(GeoSolid3 first, GeoSolid3 second, out GeoSolid3 result)

Parameters

first GeoSolid3
second GeoSolid3
result GeoSolid3

Returns

bool

TryIntersect(GeoSolid3, GeoSolid3, out GeoSolid3, Tolerance)

Gets the part two solids have in common, within a tolerance.

public static bool TryIntersect(GeoSolid3 first, GeoSolid3 second, out GeoSolid3 result, Tolerance tolerance)

Parameters

first GeoSolid3
second GeoSolid3
result GeoSolid3
tolerance Tolerance

Returns

bool

false when the two bodies share no volume, or when it cannot be worked out, which is logged.

Remarks

Only one body is cut, and only by the planes of the other that come near it and of its own openings: those are what leave every cell wholly inside or wholly outside the other, and wholly material or wholly carved out. Its own outer faces bound it already and need not cut it. On a bent bar they would: every plane of a bend runs on through the rest of the bar, and a bar with a hook came out in thousands of cells, twenty seconds against a plate. The body cut is the one fewer planes cut, so a bar crossing a beam is cut by a handful of the beam's planes rather than the beam by the hundreds of the bar's.