Skip to content

wire: vertex point access in classification merges - #755

Merged
bherbruck merged 5 commits into
tangency-labs:mainfrom
tdamsma:claude/vertex-point
Oct 24, 2026
Merged

bherbruck merged 5 commits into
tangency-labs:mainfrom
tdamsma:claude/vertex-point

Conversation

@tdamsma

@tdamsma tdamsma commented Oct 24, 2026

Copy link
Copy Markdown
Contributor

Machine-generated (Claude Opus 5.5 coordinator and agent) on behalf of @tdamsma.

What was wrong. Two calls went through opaque handles that could not reach the vertex's B-rep: MergeIntoObject in SmVertexDefinition::Imprint (the proto-topology imprint) and the SmVertex::SetPoint inside PointClassification::Combine (in InsertCurveInterval / InsertPointClass). That produced 115 SmVertex::GetPoint deferrals, 28 SmVertex::SetPoint deferrals, and 20 SmBrep mutable owning context deferrals in merge_p4.

What changed.

  • ProtoBrep::merge_point_class_into_brep (the default keeps the old deferral). ArenaPair and the TI runner's Two implement it with merge_into_object_mut. imprint_vertex_definition now takes &mut Kernel.
  • PointClassification::combine_setting_vertex_point (a caller-supplied SetPoint hook; combine_in_brep is now built on it). Imprint::combine adds insert_curve_interval_mut and insert_point_class_mut over MergeIntervalBrep, which move the vertex at the point upstream does. Upstream SetPoint only notifies ChangeGeometry and sets the point: it touches no tolerance and no cache.
  • Runners: curve_class_p6 op 0 and curve_class_p3 Insert use the _mut paths. Both sides (shim and Rust) now also report the vertex points afterwards. The proto runner merges a vertex stand-in in its own record.
  • This wiring newly compares 3 merge_p4 far-translation cases, and they failed. Cause: BooleanPostProcess's DeleteTopologicalVertex re-owned the joined curve under a kernel key, so the inverse temporary transform skipped it. boolean_post_process now puts back the surviving curve's owner identity, and all 3 pass. Details are in plan/findings.md. A cleaner fix would need kernel_adapter.rs (wire: IntersectInsertRelate into Boolean2D (primitive_creation_p1) and the PiecewiseMerge runner (merge_p3) #738).

Difftest (Mac Studio; Linux CI is the verdict), before (main CI reports) -> after:

  • intersect.curve_class_p6: 4446 pass / 20 deferred -> PASS cases=4466 passed=4466 failed=0 deferred=0 (now green)
  • intersect.curve_class_p3: 3700 / 8 -> PASS cases=3708 passed=3708 failed=0 deferred=0 (now green)
  • boolean.merge_p4: 3 rejected, 168 deferred -> PARTIAL cases=311 passed=242 failed=0 deferred=66 rejected=3 blocked_by=query.face_p2(66)
  • boolean.merge_p3: 62 deferred -> PARTIAL cases=423 passed=370 failed=0 deferred=53
  • boolean.topology_intersector_p2: 95 deferred -> PARTIAL cases=910 passed=838 failed=0 deferred=72
  • topology.proto_topology_p2: 71 deferred -> PARTIAL cases=1567 passed=1497 failed=0 deferred=70. The 25 topology.brep_p1 edge/region stand-ins are not part of any B-rep, so they stay deferred.
  • boolean.merge_p1: PASS cases=248 passed=248

Checks: mac-gates all pass (fmt, clippy with and without cpp, cargo test --workspace, wasm). Full --green on the Mac shows no new failures. local_solve1d, query.face_p4 and brep_p10 fail one case each, and they fail the same way on main on the Mac.

🤖 Generated with Claude Code

https://claude.ai/code/session_01RvuXmr7S5RoUXxVohC1giE

tdamsma and others added 3 commits October 24, 2026 15:16
SmVertexDefinition::Imprint merges its classifications through a new
ProtoBrep::merge_point_class_into_brep hook; the arena pair (and the
topology-intersector runner) implement it with merge_into_object_mut, so
MergeIntoObject reads and moves the real vertex (SmVertex::GetPoint/SetPoint)
instead of deferring on an opaque handle.

PointClassification::Combine takes the caller's SmVertex::SetPoint
(combine_setting_vertex_point); InsertCurveInterval and InsertPointClass get
_mut entry points over MergeIntervalBrep that make the move where upstream does.
The curve_class_p3/p6 runners use them and compare the vertex points after.

boolean_post_process puts back the surviving edge curve's owner identity after
DeleteTopologicalVertex, so the temporary transform's inverse still finds it
(the far-translation cases this wiring newly compares).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01RvuXmr7S5RoUXxVohC1giE
# Conflicts:
#	plan/units/boolean.merge_p3.toml
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01RvuXmr7S5RoUXxVohC1giE
@tdamsma
tdamsma marked this pull request as ready for review October 24, 2026 13:51
@bherbruck
bherbruck added this pull request to the merge queue Oct 24, 2026
@bherbruck
bherbruck removed this pull request from the merge queue due to a manual request Oct 24, 2026
@bherbruck
bherbruck added this pull request to the merge queue Oct 24, 2026
@bherbruck
bherbruck removed this pull request from the merge queue due to a manual request Oct 24, 2026
@bherbruck
bherbruck added this pull request to the merge queue Oct 24, 2026
@bherbruck
bherbruck removed this pull request from the merge queue due to a manual request Oct 24, 2026
@bherbruck
bherbruck added this pull request to the merge queue Oct 24, 2026
@bherbruck
bherbruck removed this pull request from the merge queue due to a manual request Oct 24, 2026
@bherbruck
bherbruck added this pull request to the merge queue Oct 24, 2026
@bherbruck
bherbruck removed this pull request from the merge queue due to a manual request Oct 24, 2026
tdamsma and others added 2 commits October 24, 2026 16:42
# Conflicts:
#	plan/units/boolean.merge_p3.toml
#	plan/units/boolean.merge_p4.toml
#	plan/units/boolean.topology_intersector_p2.toml
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01RvuXmr7S5RoUXxVohC1giE
@bherbruck
bherbruck added this pull request to the merge queue Oct 24, 2026
@bherbruck
bherbruck removed this pull request from the merge queue due to a manual request Oct 24, 2026
@bherbruck
bherbruck added this pull request to the merge queue Oct 24, 2026
@bherbruck
bherbruck removed this pull request from the merge queue due to a manual request Oct 24, 2026
@bherbruck
bherbruck added this pull request to the merge queue Oct 24, 2026
@bherbruck
bherbruck removed this pull request from the merge queue due to a manual request Oct 24, 2026
@bherbruck
bherbruck added this pull request to the merge queue Oct 24, 2026
Merged via the queue into tangency-labs:main with commit 8669806 Oct 24, 2026
8 checks passed
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