Expand description
IFC4X3 distance-along-curve geometry onto Axiolid stations (#307).
IfcPointByDistanceExpression (IFC4.3 ADD2 8.9.3.48) names a point by a
distance along a basis curve plus three offsets; IfcAxis2PlacementLinear
(8.9.3.4) frames one; IfcOffsetCurveByDistances (8.9.3.42) runs through
several; IfcSectionedSolidHorizontal (8.8.3.35) and
IfcSectionedSurface (8.8.3.37) stand cross sections at them. Resolving
a distance to a point is curve evaluation, which this crate never does
(ADR 0004): each lowers to Axiolid’s station relations (axiolid-model
0.3.5, ADR 0082), stored exactly, which a kernel resolves.
§Convention map
Every row is the same in IFC4.3 ADD2 and in ADR 0082, so nothing is
converted. Each is pinned by a test that resolves the lowered station
through axiolid-reference (tests only).
| IFC4.3 ADD2 | Axiolid |
|---|---|
DistanceAlong as IfcLengthMeasure, from the basis curve’s start | Station::distance |
on an IfcGradientCurve, the BaseCurve’s parameter: plan arc length (8.9.3.34.1 “the value of the parameter equals the parameter value of BaseCurve”) | plan distance on Curve3::Elevated |
| on any other curve, its arc length | arc length |
OffsetLateral, “positive values indicate to the left of the basis curve as facing in the positive parametrization direction” | StationOffsets::lateral, positive to the left |
OffsetVertical, “perpendicular to the tangent at DistanceAlong in the plane of the tangent perpendicular to the global XY plane” | vertical along the section up of StationFrame::Section: the reference-up frame, leaning back with the grade |
OffsetLongitudinal, “parallel to the basis curve after applying DistanceAlong, OffsetLateral, and OffsetVertical” | longitudinal along the tangent |
IfcAxis2PlacementLinear local X, Y, Z with Axis/RefDirection absent: the curve’s tangent, left and up (8.9.3.4.1 “relative to the curve … maintaining the relationship to the tangent”) | the base frame (tangent, lateral, up) |
Axis: “the exact direction of the local Z Axis”; RefDirection determines local X, adjusted to stay orthogonal to Axis | StationOrientation { axis, ref_direction }, components in the base frame, Gram-Schmidt with the axis primary |
WR2: Axis and RefDirection not parallel | refused at push within ORIENTATION_TOLERANCE; checked here first and refused by name |
IfcParameterValue distances are refused: IFC4.3 ADD2 states no
parameterisation for most bases, and a station is a distance.
OffsetVertical along the tangent-normal is contested
(buildingSMART/IFC4.x-development#1151 proposes global Z); this follows
the ADD2 text.
§Tangent discontinuities (#346)
8.9.3.48.3, on OffsetLateral: “If DistanceAlong coincides with a point
of tangential discontinuity (within precision limits), then the tangent
of the previous segment governs.” Axiolid states the same choice since
axiolid-model 0.3.6 (ADR 0082 amendment, axiolid/kernel#263): a
station carries a SeamSide, and SeamSide::Incoming reads the piece
that ends at the seam. So a station on a seam is lowered at the seam’s own distance with
the incoming side: an IfcAxis2PlacementLinear as an
OrientedCurveStation with SeamSide::Incoming, an
IfcPointByDistanceExpression as the unturned oriented station
CurveStation::with_seam_side(SeamSide::Incoming) gives (a plain
CurveStation always reads the outgoing piece). Off a seam nothing
changes. OffsetLongitudinal, which IFC offers “to reach locations for
the case of a tangentially discontinuous basis curve”, then runs along
the incoming tangent.
Which stations are on a seam. “Within precision limits” is the
model’s declared Precision, capped at 1 mm (Basis::tolerance; the
same cap ifc_alignment::SeamTolerance applies), or rounding,
1e-9 * max(1, |s|), where that is larger. Axiolid reads a station on a
seam within ARC_LENGTH_TOLERANCE * max(1, s) with ARC_LENGTH_TOLERANCE = 1e-12, a window inside ours. The two are reconciled by snapping: a
station within our window is stored at the seam’s distance, read from
the same stored data Axiolid reads it from (seams), so the kernel finds
it on the seam and reads the side stated. Without the snap a station
0.5 mm past a corner in a model of millimetre precision would be on the
corner for IFC and on the outgoing leg for the kernel.
Runs. Sections and offsets need no side. IFC 8.8.3.35.1: “If the
directrix is not tangent continuous, the resulting solid is created by a
miter at half angle between the two segments” (8.8.3.37.1 says the same
of the surface), and Axiolid mitres a run across a seam in the plane normal to the bisector of the two
tangents (Mitre, ADR 0082 amendment). A station of a run within
precision of a seam is snapped to it too, so the kernel stands that
section in the mitre plane instead of refusing a section the mitre would
cut. “Very sharp edges may result in nearly impossible miter”: a seam
where the curve turns back on itself (the cosine of half the turn at most
Axiolid’s MITRE_TOLERANCE, seams::MITRE_TOLERANCE) inside a run is
refused by name.
Relation bases. A plain IfcCompositeCurve, an IfcTrimmedCurve
and segments placed at stations lower to a curve relation, along which
Axiolid measures a station end to end through its pieces since
axiolid-model 0.3.7 (axiolid/kernel#285, ADR 0082 amendment): each
piece in its own curve’s convention, every joint a seam whose
SeamSide::Incoming reads the piece that ends there, IFC’s previous
segment. The joints’ distances are read from the stored relation
(relation), and a station within precision of one is snapped onto it
and reads that side, as on an atomic basis. A relation joining a
gradient curve with arc-length pieces is refused by name; a gap or an
undeclared reversed piece is refused by the kernel.
Offset bases (#414). IfcOffsetCurve2D, IfcOffsetCurve3D and
IfcOffsetCurveByDistances lower to CurveRelation::Offset and
OffsetByStations, which Axiolid measures a station along since
axiolid-mesh-compile 0.3.19 (axiolid/kernel#289, ADR 0082 amendment
2026-10-10): in the offset’s OWN length from its start, not its basis’s
(the station names a place along the curve it references), one offset
piece per span of the basis between its seams and, by distances, between
its stations, every piece boundary a joint read by the same seam rule.
IFC states an offset curve’s parameterisation, “from the basis curve”
(IFC4.3 ADD2 8.9.3.40.1), but not a distance along it other than its
length. The joints’ distances are the closed forms relation::offset
states, and where it states none (an offset whose length is a
quadrature) the kernel snaps the station (below); an offset of an
offset, a trim of an offset and a collapsed circle are refused by name,
and an offset across a corner of its basis,
whose sides do not meet (IFC: the basis “shall have a well-defined
tangent direction at every point”), is refused by the kernel.
Bases whose seams are quadratures (#423). The seams are read from
stored data, never by evaluation. Where they lie at an arc-length
integral – an offset beside a gradient curve, a spiral, a B-spline or
an ellipse, a relation with an ellipse or a B-spline piece, a B-spline’s
corner knot – this crate cannot place a station within precision of
one, and hands the snapping to the kernel instead: the station is
stored at its own distance as an OrientedCurveStation reading
SeamSide::Incoming, with the window this crate snaps within (the
declared precision, Basis::tolerance) as its seam-snapping window
(OrientedCurveStation::with_seam_window, axiolid-model 0.3.9,
axiolid/kernel#294, ADR 0082 amendment). Resolving it, the kernel reads
a station within that window of exactly one seam whose frame may jump
ON that seam, from the incoming side, at its own certified distance, and
refuses by name a window holding two seams (SEAM_WINDOW_AMBIGUOUS), a
seam whose certified position straddles its edge
(SEAM_WINDOW_STRADDLED) and a seam it cannot certify
(UNCERTIFIED_LENGTH); crate::compile names the station in a
GeometryError::StationSeamWindowRefused.
A station on a basis whose seams are stored data keeps the snapping
above, so its graph is unchanged (no window, wire format 1.0 content).
Runs along such a basis (#429). A run’s stations carry the same
window and side since axiolid-model 0.3.11 (axiolid/kernel#301, ADR
0082 amendment): a section of IfcSectionedSolidHorizontal or
IfcSectionedSurface as SectionAtStation::with_seam_window(w) and
with_seam_side(SeamSide::Incoming) (Basis::run_place), w the
same Basis::tolerance. The kernel snaps each onto the one seam
within its window, at the seam’s certified distance, and reads the run
at the snapped distances: an interior station snapped onto a seam
where the tangent turns stands in the mitre plane (its side is not
read), the first and last keep the run’s own reading, and a side is
read only on a seam where the tangents agree and the frame may jump.
Snapped distances that no longer increase strictly are refused by the
kernel by name, as are the window’s own refusals; crate::compile
names the run (GeometryError::RunSeamWindowRefused), which
ProvenanceMap::seam_window_runs lists. A reversal at such a seam,
which this crate cannot see, is refused by the kernel’s mitre. A run
along a basis whose seams are stored data keeps the snapping above and
carries no window, so its graph is unchanged (wire format 1.0 content);
only the runs that used to be refused carry windows (format 1.2). An
IfcOffsetCurveByDistances along such a basis continues its offsets to
the basis’s end, a quadrature, which the kernel measures (offset,
#433, RunStation::at_basis_end, axiolid/kernel#303; format 1.3). A
station along such a run (OffsetsAtStations) carries the window too
(#443, relation::offset::by_stations); the reference kernel
certifies an offset law that varies along an ellipse or a B-spline
since axiolid-evaluate 0.3.15 (axiolid/kernel#307), so such a window
resolves.
§Frames
The basis is lowered under the item’s frame, like every curve here. Only
a frame that is rigid and keeps world Z is admitted: a scale changes
the measure along the curve, a mirror swaps left and right, and a tilt
moves “the global XY plane” the vertical offset is read against.
Functions§
- lower_
axis2_ placement_ linear_ node - Lower an
IfcAxis2PlacementLinearinto anOrientedCurveStation. - lower_
point_ by_ distance_ node - Lower an
IfcPointByDistanceExpressioninto aCurveStation, or, on a tangent discontinuity of its basis, into the unturnedOrientedCurveStationreading the incoming side (module documentation).