Skip to content

Raw surface/surface intersection shows avoidable residual drift in difficult cases #73

@anpoit00

Description

@anpoit00

Hi,

I noticed that raw surface/surface intersection in verb can produce relatively large residuals (~1e-4) on difficult analytic cases such as oblique cone × cone.

I experimented with:

  • tighter tessellation seeding
  • decoupled refinement tolerance
  • higher refinement iteration budget

This reduces residuals down to ~1e-6–1e-7 without changing topology.

Full patch and benchmarks are here:

Changes:

  • tighten adaptive tessellation for SSI seeding
  • decouple refinement tolerance from the public API tolerance
  • raise the point-refinement budget from 5 to 12 iterations
  • use the midpoint of the two refined surface points as the final SSI sample point
  • guard against near-singular refinement updates

Measured raw SSI results (no downstream post-processing):

  • oblique_cone_x_oblique_cone

    • worst residual improved from 1.03e-4 / 1.68e-4
      to 8.01e-6 / 5.70e-6
    • topology stayed 1 open curve in both directions
  • plane_x_oblique_cone

    • worst residual improved from 8.33e-5
      to 6.19e-7
    • topology stayed 1 closed loop
  • sphere_x_cylinder

    • worst residuals improved from ~5.0e-5..6.4e-5
      to ~1.3e-7..2.2e-7
    • topology stayed 2 closed loops
  • sphere_x_sphere

    • worst residuals improved from ~2.8e-5..4.1e-5
      to ~5.6e-7..7.2e-7
    • topology stayed 1 closed loop
  • plane_x_loft

    • worst residuals improved from ~8.2e-5
      to ~1.95e-5
    • topology stayed 1 open curve

Known limitation:

  • cylinder_x_cylinder is still fragmented into 4 open pieces
  • raw topology is unchanged there, which suggests the remaining issue
    is not just a refinement-budget problem

Test coverage:
Raw SSI comparisons were rerun in both argument orders (A×B and B×A) for:

  • plane_x_cylinder
  • plane_x_loft
  • cylinder_x_cylinder
  • plane_x_oblique_cone
  • oblique_cone_x_oblique_cone
  • sphere_x_cylinder
  • sphere_x_sphere

Happy to discuss or adjust approach.

What changed

  • stricter adaptive tessellation for intersection seeding
  • refinement tolerance decoupled from the public API tolerance
  • refinement iteration budget increased from 5 to 12
  • final SSI sample point computed as the midpoint of the two refined surface projections
  • added guards against near-singular refinement updates

Evidence

Before/after raw SSI benchmarks were rerun on 7 analytic cases in both argument orders.

Case Before (worst residual) After (worst residual) Raw topology
oblique_cone_x_oblique_cone 1.68e-4 8.01e-6 / 5.70e-6 1 open curve
plane_x_oblique_cone 8.33e-5 6.19e-7 1 closed loop
sphere_x_cylinder 6.39e-5 2.18e-7 2 closed loops
sphere_x_sphere 4.08e-5 7.18e-7 1 closed loop
plane_x_loft 8.24e-5 1.95e-5 1 open curve

What did not change

  • cylinder_x_cylinder is still fragmented into 4 open pieces
  • no raw topology is healed by this patch
  • no kernel-side logic was added

Why this matters

This improves the geometric quality of hard raw SSI cases without hiding the remaining topological limitations.
That makes the raw solver output more accurate and more useful for downstream consumers.

Intersect.zip

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions