Units / surface
surface.surface_p5 green
- Layer
- 28
- Upstream lines
- 2,321
- Functions
- 16
- Rust module
surface::surface::p5
Source: crates/solidcore/src/surface/surface/p5.rs
Upstream: source/SMLib/inc/SmSurface.h, source/SMLib/src/SmSurface.cpp
Notes
UPDATE (PR #52, after merging surface_p4/#49 and surface_p5/#50): the five UNPORTED(surface.surface_p3) stubs are wired (GetSingularities, SmFindPSNormalENFO solve, UV-guess LocalSurfaceSurfaceIntersect, CoverCoincidentSurface, EvaluateNormalSection); difftest 3046 cases, 2477 pass bit-identical, 0 failed, 569 deferred (surface.surface_point_solve_p3 528, curve.iso_curve 41); --perturb SENSITIVE 2477/2477. Kernel::default() remains in the IdenticalSolutions overrides and the image-space LocalSurfaceSurfaceIntersect (no kernel threaded there). PARTIAL: difftest 3046 cases (46 fixture: Surface.sms drop-point cases of the upstream closest-point test plus singularity and iso-curve cases; 3000 generated), 1785 pass bit-identical, 1261 deferred (surface.surface_point_solve_p3 512 = LocalPointSolve_1 and the point solves of sm_SpLocalSolve/DropPoint, surface.surface_p3 728 = GetSingularities, SmFindPSNormalENFO::Evaluate and EvaluateNormalSection, curve.iso_curve 21 = SmIsoCurve over non-B-spline surfaces and planes; the 9 cases that waited on surface.surface_p6 now defer to the point solves); a 60000-case run is clean; --perturb SENSITIVE 1785/1785. Covered ops (the generated cases include SmCurve::SurfaceMaxDistanceBetween of line segments and curves over planes, which drives the DropPoint wiring of curve.curve_p2, and plane drops of points above the interior): IsSingularity (poles, pinched corners, the SmPlane override), EvaluateNormalAtSingularity, CreateIsoParametricCurve (B-spline and plane overrides; the base body only runs for curve-bounded surfaces, whose SmIsoCurve needs EvaluateSimple, surface.surface_p1, so it is deferred), LocalPointSolve_0 INTERSECT, DropPoint via DropPointFast, sm_FilterSolution and sm_SpLocalSolve (verbatim C++ copies in the shim; the latter takes the surface sm_GetSurfaceToEvaluate would return), the four IdenticalSolutions overrides. m_bUseNewPointSolvers is TRUE upstream, so LocalPointSolve (LocalPointSolve_1, surface.surface_point_solve_p3) only runs LocalPointSolve_0 for MAXIMIZE, whose Newton solve is SmFindPSNormalENFO (surface.surface_p1/p3). SmCSGlobalSolver and SmCSIGlobalSolver have no struct yet: their IdenticalSolutions are free functions (cs_identical_solutions, csi_identical_solutions). CoverOtherCoincidentSurface has upstream's full signature and fall-through; it waits on CoverCoincidentSurface (surface.surface_p3). Back-edges wired: IsSingularity (nurbs b_spline_surface p1, b_spline_surface_n_lib p1, surface_cache p1, intersect.surface_intersector_p2), LocalPointSolve (nurbs b_spline_surface p1, intersect.surface_intersector_p1/p2), EvaluateNormalAtSingularity (curve_bounded_surface), DropPoint (intersect.surface_intersector_p1, surface.plane_p1), SmSPGlobalSolver/SmLSIGlobalSolver::IdenticalSolutions (p7, p2), SmCSIGlobalSolver::IdenticalSolutions, sm_FilterSolution and LocalPointSolve (surface.surface_p9), LocalPointSolve (intersect.curve_class_p1, surface.surf_of_revolution_p3), CreateIsoParametricCurve (surface.surface_point_solve_p1, surface.surface_cache_p1), IsSingularity (intersect.surface_intersector_p3), LocalPointSolve and DropPoint through SurfaceEvaluate (nurbs.b_spline_curve_n_lib, curve.curve_p2), the STEP-surface local solve of SmSurfOfRevolution::ConvertUVFromNURBSToSTEP (surface.surf_of_revolution_p1). Still UNPORTED(surface.surface_p5): the SmCrvOnSurf branch of curve_p6. 16 fns; largest: sm_FilterSolution, SmSurface::LocalPointSolve_0, SmSurface::DropPoint, sm_SpLocalSolve; cycle back-edges (call into later units; stub or co-port): surface.surface_p1(10), surface.surface_p3(5), topology.face_p2(2), surface.surface_point_solve_p3(1); unit-SCC #22 (220 units); 317 upstream test entry points reach this unit Wired callers (PR #50 review): IsSingularity (intersect.surface_intersector_p4, topology.vertexuse), LocalPointSolve (topology.vertexuse, surface.surface_point_solve_p2), the general 3D branch of SmTol::MapTo2d (DropPoint + DropVectors, surface.surface_p1); SmFilletCustomSolver stays Unported (SmOffsetSurface is not a Surface kind: retagged surface.offset_surface). PR #125: drop_point_with_kernel supplies the caller Kernel to fast/global solves for query.api_queries; the existing drop_point signature retains its default-kernel behavior. Revalidated 3046 cases: 2477 bit-identical, 0 failed, 569 deferred; perturb 2477/2477. Re-run after merging PR #106 (surface.surface_point_solve_p3 wired, 2026-10-15): 3046 cases, 3025 pass, 21 deferred (surface.surface_p8 21), 0 failed, max_rel_err 0. drop_point now takes the caller's Kernel itself (PR #106 threads it through every caller), so PR #125's drop_point_with_kernel is folded into it. Re-run after wiring PR #118 (surface.surface_p8 and its back-edges, GlobalPointSolve_0 included): 3046 cases, 3046 pass, 0 deferred, 0 failed, max_rel_err 0; green.
Difftest
- Cases
- 3,046
- Passed
- 3,046
- Deferred
- 0
- Failed
- 0
- Both errored
- 0
- Max rel. error
- 0.0
- Tolerance
- 1e-09 rel.
- Seeds
- 16
Blocked by
Nothing: no deferred cases.
Report JSON (per-case results)
Dependencies
Depends on: curve.curve_p2 green curve.iso_curve green geom.extent1d green geom.extent2d green geom.global_solver partial geom.local_solve_nd green geom.object partial geom.solution_array partial geom.tol green geom.vector2d green geom.vector3d green surface.surface_p2 partial surface.surface_p4 green surface.surface_p7 partial
Soft dependencies: curve.curve_p1 partial curve.curve_p3 green curve.curve_p4 partial nurbs.b_spline_curve_p1 green nurbs.b_spline_curve_p2 green
Dependents: intersect.surface_drop_curve partial intersect.surface_drop_lib_p2 green intersect.surface_drop_lib_p3 claimed surface.surface_p10 partial surface.surface_p11 partial surface.surface_p6 green surface.surface_p8 partial topology.edgeuse_p3 claimed
Soft dependents: blend.fillet_corner_p1 todo blend.fillet_custom_solver partial blend.fillet_geom_p1 claimed blend.fillet_geom_p4 todo blend.fillet_solver_p1 claimed blend.fillet_standard_solver_p1 claimed blend.fillet_standard_solver_p2 todo boolean.topology_intersector_p1 partial heal.gap partial intersect.curve_class_p1 partial intersect.curve_class_p2 claimed intersect.curve_class_p4 claimed intersect.curve_class_p5 partial intersect.curve_class_p8 partial intersect.curve_class_p9 partial intersect.surface_intersector_p1 partial intersect.surface_intersector_p2 partial intersect.surface_intersector_p3 partial intersect.surface_intersector_p4 partial primitive.primitive_creation_p2 todo primitive.primitive_creation_p3 todo query.api_queries partial query.face_p1 claimed query.face_p3 claimed surface.surface_point_solve_p1 green surface.surface_point_solve_p2 green topology.brep_p1 claimed topology.brep_p3 claimed topology.brep_p8 claimed topology.brep_p9 claimed topology.edge partial topology.edgeuse_p1 partial topology.face_p1 partial topology.face_p2 partial topology.face_p3 claimed topology.face_p4 claimed topology.loopuse partial topology.proto_topology_p2 partial topology.trimming_tools partial topology.vertexuse partial
Upstream functions
| Upstream function | Defined at | Lines | Rust (from the file header) |
|---|---|---|---|
SmSurfaceEval::SectCurvature | SmSurface.h:2206 | 2 | [SurfaceEval::sect_curvature] |
sm_SpLocalSolve | SmSurface.cpp:4512 | 230 | [sp_local_solve] |
SmSurface::CoverOtherCoincidentSurface | SmSurface.cpp:8327 | 158 | [Surface::cover_other_coincident_surface], [CoverOtherCoincident] |
SmSurface::DropPoint | SmSurface.cpp:10387 | 241 | [Surface::drop_point], [DropPointOptions], [DropPoint] |
SmSurface::EvaluateNormalAtSingularity | SmSurface.cpp:10839 | 63 | [Surface::evaluate_normal_at_singularity] |
sm_FilterSolution | SmSurface.cpp:12733 | 311 | [filter_solution] |
SmCSIGlobalSolver::IdenticalSolutions | SmSurface.cpp:14784 | 86 | [cs_identical_solutions], [csi_identical_solutions] |
SmSurface::CreateIsoParametricCurve | SmSurface.cpp:14943 | 155 | [Surface::create_iso_parametric_curve], [IsoParametricCurve] |
SmCSGlobalSolver::IdenticalSolutions | SmSurface.cpp:17670 | 88 | [cs_identical_solutions], [csi_identical_solutions] |
SmLSIGlobalSolver::IdenticalSolutions | SmSurface.cpp:18843 | 88 | [SpGlobalSolver]'s and [LsiGlobalSolver]'s identical_solutions |
SmSPGlobalSolver::IdenticalSolutions | SmSurface.cpp:19879 | 84 | [SpGlobalSolver]'s and [LsiGlobalSolver]'s identical_solutions |
SmSurface::IsSingularity | SmSurface.cpp:23034 | 20 | [Surface::is_singularity], [Surface::is_singularity_with_poles], [Singularity] |
SmSurface::IsSingularity | SmSurface.cpp:23055 | 203 | [Surface::is_singularity], [Surface::is_singularity_with_poles], [Singularity] |
SmSurface::LocalPointSolve | SmSurface.cpp:26074 | 134 | [Surface::local_point_solve], [PointSolve] |
SmSurface::LocalPointSolve_0 | SmSurface.cpp:26255 | 288 | [Surface::local_point_solve_0], [PointSolve0] |
SmSurface::LocalSurfaceSurfaceIntersect | SmSurface.cpp:29029 | 170 | [Surface::local_surface_surface_intersect_xyz] |
Module file-header table (13 rows)
| Rust | Upstream |
|---|---|
[SurfaceEval::sect_curvature] | SmSurfaceEval::SectCurvature |
[Surface::is_singularity], [Surface::is_singularity_with_poles], [Singularity] | IsSingularity (both overloads; virtual: the SmPlane override) |
[Surface::evaluate_normal_at_singularity] | EvaluateNormalAtSingularity (virtual: the SmCurveBoundedSurface override) |
[Surface::create_iso_parametric_curve], [IsoParametricCurve] | CreateIsoParametricCurve (virtual: SmBSplineSurface, SmPlane; the SmSurface body for the rest) |
[Surface::local_point_solve], [PointSolve] | LocalPointSolve |
[Surface::local_point_solve_0], [PointSolve0] | LocalPointSolve_0 |
[Surface::drop_point], [DropPointOptions], [DropPoint] | DropPoint |
[Surface::local_surface_surface_intersect_xyz] | LocalSurfaceSurfaceIntersect (from an image-space guess) |
[Surface::cover_other_coincident_surface], [CoverOtherCoincident] | CoverOtherCoincidentSurface |
[sp_local_solve] | sm_SpLocalSolve (static) |
[filter_solution] | sm_FilterSolution (static) |
[SpGlobalSolver]'s and [LsiGlobalSolver]'s identical_solutions | SmSPGlobalSolver::IdenticalSolutions, SmLSIGlobalSolver::IdenticalSolutions |
[cs_identical_solutions], [csi_identical_solutions] | SmCSGlobalSolver::IdenticalSolutions, SmCSIGlobalSolver::IdenticalSolutions |
Upstream tests reaching this unit
prog_test:my_test_surface_closest_point, prog_test:my_test_drop_point, prog_test:my_test_matrix, prog_test:my_test_reversed_line_join, SM_API_test:TestSmCreateRectangle, SM_API_test:TestSmCreateRegularPolygon