solidcore

Units / surface

surface.surface_cache_p1 green

Layer
22
Upstream lines
1,944
Functions
43
Rust module
surface::surface_cache::p1

Source: crates/solidcore/src/surface/surface_cache/p1.rs

Upstream: source/SMLib/inc/SmSurfaceCache.h, source/SMLib/src/SmSurfaceCache.cpp

Notes

PARTIAL: difftest 872 cases (72 fixture + 800 generated), 709 pass bit-identical, 163 deferred (surface.surface_p7 107: SmSurface::EvaluateNormal in every polar box and at collinear boundary samples; surface.surface_p5 37: SmSurface::IsSingularity in every Bezier approximation; surface.surface_p1 19: GetFace); 20k-seed run clean, --perturb SENSITIVE; co-ports SmSurfaceCache's constructor field init and GetTree's existing-tree path (surface.surface_cache_p3); wired UNPORTED(surface.surface_cache_p1): SmTree::GetOwnerObject of surface trees (Tree::set_owner_surface), sm_GetOriginalSurface; retagged the bare-tree patch data stubs (GetFirstBezierPatch, SmSurfaceGridElement::Init, sm_CsArePerpenDisjoint) to surface.surface_cache_p3 and smsurf_GetSurfaceCache / ExpandHierarchy to surface.surface_p1 (CacheMakeOrValidate); geom.tree 7 and geom.grid 2 deferred now blocked by those; open self-stubs UNPORTED(surface.surface_cache_p1): SmPlane / SmSurfOfRevolution::CreateIsoParametricCurve (ported in surface.plane_p1 / surface.surf_of_revolution_p1, but the cache stores iso curves as BSplineCurve; wiring needs Curve storage; 8 surface.surface_cache_p3 cases defer at the SmPlane one; retagged by surface.surf_of_revolution_p3); 43 fns; largest: sm_ComputeBezierApproximation, SmSurfaceCache::MarkFaceContainment, SmSurfaceCache::BuildTreeTop, SmPatchBoundaryBoundingPlanes::ComputeBoundingPlanes; cycle back-edges (call into later units; stub or co-port): surface.surface_p5(3), surface.surface_p1(2), surface.surface_cache_p3(1), surface.surface_p7(1); unit-SCC #22 (220 units); 319 upstream test entry points reach this unit Re-run with surface.surface_p5's back-edges wired (PR #50): cases=872 passed=835 failed=0 deferred=37 max_rel_err=0e0 blocked_by=surface.surface_p3(37). GREEN (PR #52, after merging surface_p4/#49 and surface_p5/#50): 872/872 pass, 0 deferred.

Difftest

Cases
872
Passed
872
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: geom.extent2d green geom.extent3d green geom.object partial geom.tree partial geom.vector2d green geom.vector3d green nurbs.b_spline_curve_p1 green surface.surface_p2 partial

Soft dependencies: curve.curve_p2 green geom.extent1d green geom.polar_box green geom.tol green nurbs.b_spline_curve_p2 green nurbs.b_spline_curve_p3 partial nurbs.b_spline_surface_p1 green nurbs.b_spline_surface_p2 partial

Dependents: intersect.adv_surface_intersector partial intersect.surface_drop_curve partial intersect.surface_tracer partial query.tess partial surface.surface_cache_p2 partial surface.surface_cache_p3 partial surface.surface_p1 partial surface.surface_p10 partial surface.surface_p11 partial surface.surface_p7 partial surface.surface_p8 partial surface.surface_p9 partial surface.trim_srf_cache partial

Soft dependents: intersect.curve_class_p9 partial intersect.surface_intersector_p2 partial intersect.surface_intersector_p3 partial intersect.surface_intersector_p4 partial intersect.surface_intersector_p5 partial intersect.surface_silhouette green intersect.topology_solver_p1 partial surface.surface_p4 green

Upstream functions

Upstream functionDefined atLinesRust (from the file header)
SmBezierAux2d::GetUVDomainSmSurfaceCache.h:4131[BezierAux2d], [BezierAux2d::uv_domain]
SmBezierPatch::GetPseudoBoxSmSurfaceCache.h:4721[BezierPatch], [BezierPatch::pseudo_box], [BezierPatch::bezier]
SmBezierPatch::GetBezierPtrSmSurfaceCache.h:4731[BezierPatch], [BezierPatch::pseudo_box], [BezierPatch::bezier]
SmSurfaceCache::GetProcessBoundaryCurvesSmSurfaceCache.h:7771[SurfaceCache::process_boundary_curves]
SmSurfaceCache::GetPatchCountSmSurfaceCache.h:7791[SurfaceCache::patch_count], [SurfaceCache::patch_at]
SmSurfaceCache::GetPatchAtSmSurfaceCache.h:78113[SurfaceCache::patch_count], [SurfaceCache::patch_at]
SmSurfaceCache::GetUContinuitiesArraySmSurfaceCache.h:8121[SurfaceCache::u_continuities], [SurfaceCache::v_continuities]
SmSurfaceCache::GetVContinuitiesArraySmSurfaceCache.h:8131[SurfaceCache::u_continuities], [SurfaceCache::v_continuities]
SmSurfaceCache::GetSurfaceSmSurfaceCache.h:8811[SurfaceCache::surface]
SmSurfaceCache::ImplantEdgeuseSmSurfaceCache.h:93212[SurfaceCache::implant_edgeuse], [SurfaceCache::implant_poly_edge]
SmSurfaceCache::ImplantPolyEdgeSmSurfaceCache.h:9467[SurfaceCache::implant_edgeuse], [SurfaceCache::implant_poly_edge]
SmSurfaceCache::GetPatchBoundaryBoundingPlanesSmSurfaceCache.h:9894[SurfaceCache::patch_boundary_bounding_planes]
SmSurfaceCache::GetTypeSmSurfaceCache.h:10421[TYPE], [TYPE_STRING], [SurfaceCache::type_code], [SurfaceCache::type_string]
SmSurfaceCache::GetTypeStringSmSurfaceCache.h:10421[TYPE], [TYPE_STRING], [SurfaceCache::type_code], [SurfaceCache::type_string]
SmPatchBoundaryBoundingPlanes::SmPatchBoundaryBoundingPlanesSmSurfaceCache.cpp:989[PatchBoundaryBoundingPlanes], [PB_SAMPLE_COUNT]
SmPatchBoundaryBoundingPlanes::~SmPatchBoundaryBoundingPlanesSmSurfaceCache.cpp:1134Drop (implicit)
sm_CheckBoundingPlaneSeparatingHalfspaceSmSurfaceCache.cpp:19260[check_bounding_plane_separating_halfspace]
sm_ComputePlaneFrom3PointsSmSurfaceCache.cpp:26063[compute_plane_from_3_points], [PlaneFrom3Points]
SmPatchBoundaryBoundingPlanes::CreateBoundaryCurveForIndexSmSurfaceCache.cpp:33235[PatchBoundaryBoundingPlanes::create_boundary_curve_for_index]
SmPatchBoundaryBoundingPlanes::GetBoundaryUVEndPointsSmSurfaceCache.cpp:37531[PatchBoundaryBoundingPlanes::boundary_uv_end_points]
SmPatchBoundaryBoundingPlanes::ComputeBoundingPlanesSmSurfaceCache.cpp:415170[PatchBoundaryBoundingPlanes::compute_bounding_planes]
sm_ComputeBezierApproximationSmSurfaceCache.cpp:679233[compute_bezier_approximation]
SmSurfaceCache::ComputeSizeTolerancesSmSurfaceCache.cpp:91840[SurfaceCache::size_tolerances_from_corners], [SizeTolerances]
SmSurfaceCache::ComputeSizeTolerancesSmSurfaceCache.cpp:96482[SurfaceCache::size_tolerances_from_corners], [SizeTolerances]
SmSurfaceCache::GetCornersSmSurfaceCache.cpp:105240[SurfaceCache::corners], [Corners]
SmAltSrfCache::SmAltSrfCacheSmSurfaceCache.cpp:110036[AltSrfCache::new]
SmAltSrfCache::~SmAltSrfCacheSmSurfaceCache.cpp:114316Drop (implicit)
SmBezierAux2d::GetPolarBoxSmSurfaceCache.cpp:11678[SurfaceCache::polar_box], [SurfaceCache::polar_box_unstored]
SmBezierAux2d::BuildPolarBoxSmSurfaceCache.cpp:1184123[SurfaceCache::build_polar_box]
SmAltSrfCache::MatchCacheSmSurfaceCache.cpp:131329[AltSrfCache::match_cache]
SmAltSrfCache::GetCopyOfCurvesSmSurfaceCache.cpp:135353[AltSrfCache::copy_of_curves], [AltSrfCache::copy_of_curves_partial], [CopyOfCurves]
SmSurfaceCache::HasCachedCurvesSmSurfaceCache.cpp:141546[SurfaceCache::has_cached_curves]
SmSurfaceCache::FindUnmarkedLeafNodeSmSurfaceCache.cpp:161747[SurfaceCache::find_unmarked_leaf_node]
SmSurfaceCache::GetSurfaceContinuitySmSurfaceCache.cpp:167254[SurfaceCache::surface_continuity]
SmSurfaceCache::GetConnectedRegionSmSurfaceCache.cpp:1734151[SurfaceCache::connected_region], [ConnectedRegion]
SmSurfaceCache::MarkFaceContainmentSmSurfaceCache.cpp:1901223[SurfaceCache::mark_face_containment]
sm_CullArraySmSurfaceCache.cpp:399616[cull_array]
SmSurfaceCache::BuildTreeTopSmSurfaceCache.cpp:5488194[SurfaceCache::build_tree_top]
SmSurfaceCache::GetIsoBoundaryCurvesSmSurfaceCache.cpp:580685[SurfaceCache::iso_boundary_curves], [IsoBoundaryCurves]
SmSurfaceCache::GetFaceSmSurfaceCache.cpp:59656[SurfaceCache::face]
SmSurfaceCache::PointTestSmSurfaceCache.cpp:602623[SurfaceCache::point_test]
SmSurfaceCache::PointClassifySmSurfaceCache.cpp:605617[SurfaceCache::point_classify]
SmSurfaceCache::IsKindOfSmSurfaceCache.cpp:62614[is_kind_of], [SurfaceCache::is_kind_of]
Module file-header table (42 rows)
RustUpstream
[PatchBoundaryBoundingPlanes], [PB_SAMPLE_COUNT]SmPatchBoundaryBoundingPlanes, SM_PB_SAMPLECOUNT
[PatchBoundaryBoundingPlanes::new]SmPatchBoundaryBoundingPlanes(const SmSurface*, const SmExtent2d&)
Drop (implicit)~SmPatchBoundaryBoundingPlanes
[PatchBoundaryBoundingPlanes::compute_bounding_planes]ComputeBoundingPlanes
[PatchBoundaryBoundingPlanes::create_boundary_curve_for_index]CreateBoundaryCurveForIndex
[PatchBoundaryBoundingPlanes::boundary_uv_end_points]GetBoundaryUVEndPoints
[check_bounding_plane_separating_halfspace]sm_CheckBoundingPlaneSeparatingHalfspace (static)
[compute_plane_from_3_points], [PlaneFrom3Points]sm_ComputePlaneFrom3Points (static)
[compute_bezier_approximation]sm_ComputeBezierApproximation (static)
[cull_array]sm_CullArray (static)
[BezierAux2d], [BezierAux2d::uv_domain]SmBezierAux2d, GetUVDomain
[SurfaceCache::polar_box], [SurfaceCache::polar_box_unstored]SmBezierAux2d::GetPolarBox
[SurfaceCache::build_polar_box]SmBezierAux2d::BuildPolarBox
[BezierPatch], [BezierPatch::pseudo_box], [BezierPatch::bezier]SmBezierPatch, GetPseudoBox, GetBezierPtr
[AltSrfCache], [AltSrfCacheType], [AltCacheKey]SmAltSrfCache, SmAltSrfCacheType, the user data arguments
[AltSrfCache::new]SmAltSrfCache::SmAltSrfCache
Drop (implicit)SmAltSrfCache::~SmAltSrfCache
[AltSrfCache::match_cache]SmAltSrfCache::MatchCache
[AltSrfCache::copy_of_curves], [AltSrfCache::copy_of_curves_partial], [CopyOfCurves]SmAltSrfCache::GetCopyOfCurves
[SurfaceCache], [SurfaceCacheOptions], [SurfaceCache::new]SmSurfaceCache, its constructor arguments, the field initialisation of SmSurfaceCache::SmSurfaceCache (see deviations)
[SurfaceCache::has_cached_curves]SmSurfaceCache::HasCachedCurves
[SurfaceCache::find_unmarked_leaf_node]SmSurfaceCache::FindUnmarkedLeafNode
[SurfaceCache::first_bezier_patch]SmTreeNode::GetFirstBezierPatch (unit geom.tree) on the cache's data
[SurfaceCache::surface_continuity]SmSurfaceCache::GetSurfaceContinuity
[SurfaceCache::connected_region], [ConnectedRegion]SmSurfaceCache::GetConnectedRegion
[SurfaceCache::mark_face_containment]SmSurfaceCache::MarkFaceContainment
[SurfaceCache::build_tree_top]SmSurfaceCache::BuildTreeTop
[SurfaceCache::iso_boundary_curves], [IsoBoundaryCurves]SmSurfaceCache::GetIsoBoundaryCurves
[SurfaceCache::size_tolerances_from_corners], [SizeTolerances]ComputeSizeTolerances (corner point version)
[SurfaceCache::size_tolerances_from_surface]ComputeSizeTolerances (surface version)
[SurfaceCache::corners], [Corners]SmSurfaceCache::GetCorners
[SurfaceCache::face]SmSurfaceCache::GetFace
[SurfaceCache::point_test]SmSurfaceCache::PointTest
[SurfaceCache::point_classify]SmSurfaceCache::PointClassify
[SurfaceCache::implant_edgeuse], [SurfaceCache::implant_poly_edge]ImplantEdgeuse, ImplantPolyEdge (base class)
[SurfaceCache::process_boundary_curves]GetProcessBoundaryCurves
[SurfaceCache::patch_count], [SurfaceCache::patch_at]GetPatchCount, GetPatchAt
[SurfaceCache::u_continuities], [SurfaceCache::v_continuities]GetUContinuitiesArray, GetVContinuitiesArray
[SurfaceCache::surface]SmSurfaceCache::GetSurface
[SurfaceCache::patch_boundary_bounding_planes]GetPatchBoundaryBoundingPlanes
[TYPE], [TYPE_STRING], [SurfaceCache::type_code], [SurfaceCache::type_string]GetType, GetTypeString (SM_COMMON)
[is_kind_of], [SurfaceCache::is_kind_of]SmSurfaceCache::IsKindOf

Upstream tests reaching this unit

prog_test:my_test_extent3d, prog_test:my_test_vector2d, 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