Shapemetry API / Edge
Class: Edge
Defined in: nurbsBrep/topo/Edge.ts:28
A topological edge: a 3D curve bounded by a start and end vertex. The geometric carrier is a Curve adapter from the geom layer; the parameter window is read straight from that curve's natural range.
Three boolean flags carry the same per-edge metadata OCCT's BRep_TEdge stores, so the structural role of an edge is explicit rather than re-derived:
degenerate— the edge collapses to a single point (its 3D carrier has no length) yet exists to keep a face's parameter boundary closed. The two pole edges of a sphere are the canonical case: they pin the v = ±π/2 rows of the surface domain to the pole vertex. Distinct fromisClosed(), which is also true for a full-circle rim (a closed edge WITH length); a caller that must tell a pole apart from a rim reads this flag, notisClosed().sameParameter— every pcurve of the edge shares the 3D carrier's parametrization, i.e.surface(pcurve(t)) ≈ curve3d(t)at the samet, so a point on the edge can be evaluated through either representation without converting the parameter. Validation lowers it tofalsewhen a pcurve drifts from the 3D curve. MirrorsBRep_TEdge::SameParameter.sameRange— every pcurve covers the SAME parameter interval as the 3D carrier (pcurve.range() == curve3d.range()). MirrorsBRep_TEdge::SameRange.
Constructors
Constructor
new Edge(
curve,start,end,tolerance?,degenerate?):Edge
Defined in: nurbsBrep/topo/Edge.ts:38
Parameters
curve
Curve
start
end
tolerance?
number = 1e-7
degenerate?
boolean = false
Returns
Edge
Properties
index
readonlyindex:number
Defined in: nurbsBrep/topo/Edge.ts:29
curve
curve:
Curve
Defined in: nurbsBrep/topo/Edge.ts:30
start
start:
Vertex
Defined in: nurbsBrep/topo/Edge.ts:31
end
end:
Vertex
Defined in: nurbsBrep/topo/Edge.ts:32
tolerance
tolerance:
number
Defined in: nurbsBrep/topo/Edge.ts:33
degenerate
degenerate:
boolean
Defined in: nurbsBrep/topo/Edge.ts:34
sameParameter
sameParameter:
boolean
Defined in: nurbsBrep/topo/Edge.ts:35
sameRange
sameRange:
boolean
Defined in: nurbsBrep/topo/Edge.ts:36
Methods
equals()
equals(
other):boolean
Defined in: nurbsBrep/topo/Edge.ts:58
Identity comparison: two references denote the same edge.
Parameters
other
Edge
Returns
boolean
isClosed()
isClosed():
boolean
Defined in: nurbsBrep/topo/Edge.ts:67
True when the two endpoints are the same vertex (a closed loop edge). This holds for BOTH a full-circle rim and a degenerate pole edge — use degenerate to tell those apart.
Returns
boolean
parameterRange()
parameterRange(): [
number,number]
Defined in: nurbsBrep/topo/Edge.ts:72
Parameter interval inherited from the carrier curve.
Returns
[number, number]