Skip to content

Modeling Data - Integrate EvalRep descriptors and dispatch for Geom/Geom2d#1089

Merged
dpasukhi merged 3 commits intoOpen-Cascade-SAS:IRfrom
dpasukhi:complex_geometry_equalent_surface
Feb 15, 2026
Merged

Modeling Data - Integrate EvalRep descriptors and dispatch for Geom/Geom2d#1089
dpasukhi merged 3 commits intoOpen-Cascade-SAS:IRfrom
dpasukhi:complex_geometry_equalent_surface

Conversation

@dpasukhi
Copy link
Member

Introduce EvalRep descriptors for selected Geom and Geom2d curve/surface classes and add inline EvalRep utilities for evaluation dispatch with fallback to native paths.

  • add per-class Set/Get/Clear EvalRepresentation API and storage
  • support full, derivative-bounded and mapped descriptors
  • validate mapped parameter transforms in SetEvalRepresentation()
  • migrate Geom_OffsetSurface equivalent-surface path to EvalRep
  • clone EvalRep descriptors in copy constructors and Copy() paths
  • update adaptors to use EvalRep in supported branches
  • keep EvalRep invalidation in geometry mutators and fix regressions

…eom2d

Introduce EvalRep descriptors for selected Geom and Geom2d curve/surface
classes and add inline EvalRep utilities for evaluation dispatch with
fallback to native paths.

- add per-class Set/Get/Clear EvalRepresentation API and storage
- support full, derivative-bounded and mapped descriptors
- validate mapped parameter transforms in SetEvalRepresentation()
- migrate Geom_OffsetSurface equivalent-surface path to EvalRep
- clone EvalRep descriptors in copy constructors and Copy() paths
- update adaptors to use EvalRep in supported branches
- keep EvalRep invalidation in geometry mutators and fix regressions
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This pull request introduces an evaluation representation (EvalRep) system for Geom and Geom2d curve/surface classes. The feature allows attaching alternative geometric representations to curves and surfaces for optimized evaluation, with support for parameter mapping, derivative bounds, and domain restrictions.

Changes:

  • Adds EvalRep descriptor class hierarchy (Full, DerivBounded, Mapped) with validation and cloning utilities
  • Integrates Set/Get/ClearEvalRepresentation API into Bezier, BSpline, Offset, Revolution, and Extrusion classes
  • Migrates Geom_OffsetSurface from equivSurf field to EvalRep system
  • Updates adaptors to dispatch to EvalRep when available with fallback to native evaluation
  • Ensures EvalRep invalidation on geometry mutations

Reviewed changes

Copilot reviewed 38 out of 38 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
Geom_EvalRepCurveDesc.hxx Defines 3D curve descriptor hierarchy with Map1d and Domain1d helpers
Geom_EvalRepSurfaceDesc.hxx Defines 3D surface descriptor hierarchy with Map2d and Domain2d helpers including UV swap
Geom2d_EvalRepCurveDesc.hxx Defines 2D curve descriptor hierarchy (parallel to 3D version)
Geom_EvalRepUtils.pxx Implements validation, cloning, and dispatch utilities for 3D curves/surfaces
Geom2d_EvalRepUtils.pxx Implements validation, cloning, and dispatch utilities for 2D curves
Geom_BezierCurve.{hxx,cxx} Adds EvalRep API, storage, cloning, and dispatch with mutator invalidation
Geom_BSplineCurve.{hxx,cxx} Adds EvalRep API, storage, cloning, and dispatch with mutator invalidation
Geom_BezierSurface.{hxx,cxx} Adds EvalRep API, storage, cloning, and dispatch with mutator invalidation
Geom_BSplineSurface.{hxx,cxx} Adds EvalRep API, storage, cloning, and dispatch with mutator invalidation
Geom_OffsetCurve.{hxx,cxx} Adds EvalRep API, storage, cloning, and dispatch with mutator invalidation
Geom_OffsetSurface.{hxx,cxx} Migrates from equivSurf to EvalRep with helper functions
Geom_SurfaceOfRevolution.{hxx,cxx} Adds EvalRep API, storage, cloning, and dispatch with mutator invalidation
Geom_SurfaceOfLinearExtrusion.{hxx,cxx} Adds EvalRep API, storage, cloning, and dispatch with mutator invalidation
Geom2d_BezierCurve.{hxx,cxx} Parallel 2D implementation with EvalRep support
Geom2d_BSplineCurve.{hxx,cxx} Parallel 2D implementation with EvalRep support
Geom2d_OffsetCurve.{hxx,cxx} Parallel 2D implementation with EvalRep support
GeomAdaptor_Curve.{hxx,cxx} Adds EvalRep field to BezierData/BSplineData/OffsetData with dispatch logic
GeomAdaptor_Surface.{hxx,cxx} Adds EvalRep field to all surface data variants with dispatch logic
Geom2dAdaptor_Curve.{hxx,cxx} Parallel 2D adaptor implementation with EvalRep support
FILES.cmake (Geom, Geom2d) Registers new descriptor and utility header files
Comments suppressed due to low confidence (2)

src/ModelingData/TKG3d/Geom/Geom_SurfaceOfLinearExtrusion.cxx:256

  • The unused parameter V in the original EvalDN signature has been replaced with a used parameter. This changes the function signature semantically. While the parameter is now properly used in the EvalRep path (line 263), verify that this doesn't break any existing callers that may have relied on the parameter being ignored.
    src/ModelingData/TKG3d/Geom/Geom_OffsetSurface.hxx:372
  • The removed field equivSurf was used in multiple locations (UIso, VIso, TransformParameters, DumpJson). Verify that all these usages have been correctly migrated to use the directRepSurface() helper which extracts the equivalent surface from the EvalRep descriptor. Missing migrations could cause runtime failures.

@dpasukhi dpasukhi merged commit 13d6dfc into Open-Cascade-SAS:IR Feb 15, 2026
18 checks passed
@dpasukhi dpasukhi deleted the complex_geometry_equalent_surface branch February 15, 2026 09:26
@github-project-automation github-project-automation bot moved this from Todo to Done in Maintenance Feb 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

2 participants