Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions tools/WktIntakeWalker/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,10 @@ First slice: Point, LineString, CircularString, CompoundCurve of those,
Circle-as-full-span-arc. Unknown well-formed CS/Circle maps to `MkCirc`
via the unique circumcircle (angles letter). Both CLOTHOID surface
forms (ISO REFERENCELOCATION, JTS `(k0,k1,L)`) map to the same
`MkClothoid` bag (OGC≡ISO). Fail-closed Declines: `GEODESICSTRING`,
`SPIRALCURVE`, collinear (`ID_Collinear`), duplicate control
`MkClothoid` bag (OGC≡ISO). Well-formed `GEODESICSTRING` (`n≥2`) maps
to the same `MkChord` bag as `LINESTRING` (Rocq μ in #744
`0007-intake-geodesic`). Fail-closed Declines: empty / singleton
geodesic, `SPIRALCURVE`, collinear (`ID_Collinear`), duplicate control
(`ID_DuplicateControl`), bad count / empty. No silent chord demote.
`ID_CircGammaLeftover` / `ID_IsoClothoid` / `ID_MkOutOfScope` stay
on the Decline type; they are not the well-formed clothoid answer.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ public IntakeResult visitCurveMember(wktParser.CurveMemberContext ctx) {
return visit(ctx.circleGeometry());
}
if (ctx.geodesicStringGeometry() != null) {
return IntakeResult.decline(Reason.ID_GeodesicString);
return visit(ctx.geodesicStringGeometry());
}
if (ctx.clothoidGeometry() != null) {
return visit(ctx.clothoidGeometry());
Expand All @@ -133,7 +133,10 @@ public IntakeResult visitClothoidGeometry(wktParser.ClothoidGeometryContext ctx)

@Override
public IntakeResult visitGeodesicStringGeometry(wktParser.GeodesicStringGeometryContext ctx) {
return IntakeResult.decline(Reason.ID_GeodesicString);
if (ctx.dim() != null) {
return IntakeResult.decline(Reason.ID_NotFirstSlice);
}
return mapLineString(pointsOf(ctx.lineStringText()));
}

@Override
Expand Down
6 changes: 5 additions & 1 deletion tools/WktIntakeWalker/smoke.sh
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,11 @@ check "DECLINE ID_Collinear" "CIRCULARSTRING (0 0, 1 0, 2 0)"
check "DECLINE ID_DuplicateControl" "CIRCULARSTRING (0 0, 0 0, 1 1)"
check "DECLINE ID_BadPointCount" "CIRCULARSTRING (0 0, 1 0)"
check "DECLINE ID_Empty" "CIRCULARSTRING EMPTY"
check "DECLINE ID_GeodesicString" "GEODESICSTRING (0 0, 1 0)"
check "BAG hens=0,1 pts=0 0;2 0 chickens=0-1:MkChord" "GEODESICSTRING (0 0, 2 0)"
check "DECLINE ID_Empty" "GEODESICSTRING EMPTY"
check "DECLINE ID_BadPointCount" "GEODESICSTRING (0 0)"
check "BAG hens=0,1,2,3 pts=0 0;5 0;5 0;7 0 chickens=0-1:MkChord,2-3:MkChord" \
"COMPOUNDCURVE ((0 0, 5 0), GEODESICSTRING (5 0, 7 0))"
check "DECLINE ID_SpiralCurve" "SPIRALCURVE EMPTY"
check "BAG hens=0,1 pts=0 0;80 5.333333333333333 chickens=0-1:MkClothoid" "CLOTHOID (0, 0.005, 80)"
check "BAG hens=0,1 pts=0 0;80 5.333333333333333 chickens=0-1:MkClothoid" \
Expand Down
Loading