Skip to content

HP.2 CurveHotPixel in jts-curve (arc ∩ pixel) - #29

Draft
grootstebozewolf wants to merge 1 commit into
cursor/hp1-wrong-ring-walk-f5bbfrom
cursor/hp2-curve-hotpixel-5bb4
Draft

HP.2 CurveHotPixel in jts-curve (arc ∩ pixel)#29
grootstebozewolf wants to merge 1 commit into
cursor/hp1-wrong-ring-walk-f5bbfrom
cursor/hp2-curve-hotpixel-5bb4

Conversation

@grootstebozewolf

@grootstebozewolf grootstebozewolf commented Aug 16, 2026

Copy link
Copy Markdown
Owner

Stacked on #26 @ 1b06a57. Sibling of P2.5.5, not the 74-file blast.

HP.0 / HP.1 done. This is HP.2 only.

What CurveHotPixel is

A package-private pixel around one node in org.locationtech.jts.operation.overlayng.curve. The square / half-open / scale contract matches snap-rounding (width 1/scale, left and bottom closed, top and right open). Intersection is arc ∩ pixel in the squared metric: circle–square / arc–AABB in scaled space, then restricted to the sweep. Not the supporting chord. Not HotPixel.intersectsScaled. Not a densified polyline.

The first pin is the H-SHELL-N-ODD tangent at (0, 5) (documented scale 10, pixel width 0.1):

  • HALF_DISC and STADIUM_ODD arcs that leave that node hit the pixel — one intersection node, not a chord fake.
  • HALF_HANGING's circular member misses (the pixel sits inside that disc: d²_max < r²).
  • The supporting chords (HALF_DISC diameter y=0, STADIUM_ODD cap y=4) miss. That is the lie intersectsScaled on a chord would tell.

This rung does not snap leave-angles and does not walk faces.

Never list (catalog)

What this is not

  • Not HP.3 (snap leave-angles onto distinct grid headings)
  • Not HP.4 (faces after snap)
  • Not P2.5.5 / core HotPixel / core SegmentString
  • Does not rewrite HP.1 (testCurvatureOrderWalksWrongRings, 18.42 vs pair-kit 13π+2)
  • Does not rewrite the P2.5.4 stamp (testN3TangentStampsNull / missReason P2.5.4 tangent leave-angle)
  • N=2 pair kits and N=3 nine faces unchanged

Verify

Same suite as #26. Slack 15%. OverlayNGCurve never Curved. All green after this revision:

  • CurveSegmentStringTest 28 / 0 (testN3TangentStampsNull and testCurvatureOrderWalksWrongRings unchanged; three HP.2 pins added)
  • CompoundCurveShellOverlayTest 27 / 0
  • CircularArcOverlayTest 11 / 0
  • CircularDiscOverlayTest 12 / 0
  • CircularDiscPolygonOverlayTest 7 / 0
  • CircularLineOverlayTest 7 / 0
  • OverlayNGCurvePhase0Test 19 / 0
  • OverlayNGCurveRatchetTest 50 / 0
  • OverlayNGCurvePerfGateTest 82 / 0 (15% slack)
  • Naming-guard OK; Checkstyle 0 violations; PMD check on jts-curve succeeded
mvn -pl modules/curve -am test -DfailIfNoTests=false -Dcheckstyle.skip=true -Dpmd.skip=true \
  -Dtest=CurveSegmentStringTest,CompoundCurveShellOverlayTest,CircularArcOverlayTest,CircularDiscOverlayTest,CircularDiscPolygonOverlayTest,CircularLineOverlayTest,OverlayNGCurvePhase0Test,OverlayNGCurveRatchetTest,OverlayNGCurvePerfGateTest
bash dev/check-no-curved.sh
mvn -pl modules/curve checkstyle:check
mvn -pl modules/curve pmd:check

No noder was written. Core HotPixel.java was not edited. HP.1 pin and P2.5.4 stamp unchanged. HP.3 / HP.4 / P2.5.5 were not started.

Open in Web Open in Cursor 

Package-private pixel around one node. Intersection is circle–square
in the scaled (squared) metric, not the supporting chord and not
core HotPixel.intersectsScaled. Pins the (0, 5) tangent on the
existing H-SHELL-N-ODD fixtures. Does not snap leave-angles or walk
faces.

Co-authored-by: Jeroen Bloemscheer <grootstebozewolf@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants