[netgen] OCCT compat fixes (#52085)

This commit is contained in:
Victor Romero 2026-06-01 16:34:59 -07:00 committed by GitHub
parent eae1680538
commit 2979dbff1b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
7 changed files with 420 additions and 173 deletions

View File

@ -1,158 +0,0 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 47cbae1..d277630 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -375,25 +375,20 @@ if (USE_OCC)
TKGeomAlgo
TKGeomBase
TKHLR
- TKIGES
TKLCAF
TKMath
TKMesh
TKOffset
TKPrim
- TKSTEP
- TKSTEP209
- TKSTEPAttr
- TKSTEPBase
- TKSTL
+ TKDESTL
TKService
TKShHealing
TKTopAlgo
TKV3d
TKVCAF
TKXCAF
- TKXDEIGES
- TKXDESTEP
+ TKDEIGES
+ TKDESTEP
TKXSBase
TKernel
)
diff --git a/libsrc/occ/Partition_Loop3d.hxx b/libsrc/occ/Partition_Loop3d.hxx
index e171669..fe77b90 100644
--- a/libsrc/occ/Partition_Loop3d.hxx
+++ b/libsrc/occ/Partition_Loop3d.hxx
@@ -10,27 +10,17 @@
#ifndef _Partition_Loop3d_HeaderFile
#define _Partition_Loop3d_HeaderFile
-#ifndef _TopTools_ListOfShape_HeaderFile
-#include <TopTools_ListOfShape.hxx>
-#endif
-#ifndef _TopTools_IndexedDataMapOfShapeListOfShape_HeaderFile
-#include <TopTools_IndexedDataMapOfShapeListOfShape.hxx>
-#endif
-#ifndef _Standard_Boolean_HeaderFile
+#include <Standard_Version.hxx>
#include <Standard_Boolean.hxx>
-#endif
-#ifndef _Standard_Real_HeaderFile
#include <Standard_Real.hxx>
-#endif
-#ifndef _Standard_Version_HeaderFile
#include <Standard_Version.hxx>
-#endif
+#include <TopTools_ListOfShape.hxx>
+#include <TopTools_IndexedDataMapOfShapeListOfShape.hxx>
-#if OCC_VERSION_HEX < 0x070000
+#if OCC_VERSION_HEX < 0x070000 || OCC_VERSION_HEX > 0x070799
#else
#include <TopTools_ShapeMapHasher.hxx>
#include <TopTools_OrientedShapeMapHasher.hxx>
- #include <TopTools_MapOfOrientedShape.hxx>
#endif
class TopoDS_Shape;
@@ -38,6 +28,8 @@ class TopoDS_Shape;
#if OCC_VERSION_HEX < 0x070000
class TopTools_ListOfShape;
class TopTools_MapOfOrientedShape;
+#else
+#include <TopTools_MapOfOrientedShape.hxx>
#endif
class TopoDS_Edge;
diff --git a/libsrc/occ/occ_edge.cpp b/libsrc/occ/occ_edge.cpp
index 4805bb1..bb2b98e 100644
--- a/libsrc/occ/occ_edge.cpp
+++ b/libsrc/occ/occ_edge.cpp
@@ -55,7 +55,11 @@ namespace netgen
size_t OCCEdge::GetHash() const
{
+#if OCC_VERSION_HEX < 0x070800
return edge.HashCode(std::numeric_limits<Standard_Integer>::max());
+#else
+ return std::hash<TopoDS_Shape>{}(edge);
+#endif
}
void OCCEdge::ProjectPoint(Point<3>& p, EdgePointGeomInfo* gi) const
diff --git a/libsrc/occ/occ_face.cpp b/libsrc/occ/occ_face.cpp
index 239982a..ea4dd15 100644
--- a/libsrc/occ/occ_face.cpp
+++ b/libsrc/occ/occ_face.cpp
@@ -32,7 +32,11 @@ namespace netgen
size_t OCCFace::GetHash() const
{
+#if OCC_VERSION_HEX < 0x070800
return face.HashCode(std::numeric_limits<Standard_Integer>::max());
+#else
+ return std::hash<TopoDS_Shape>{}(face);
+#endif
}
Point<3> OCCFace::GetCenter() const
diff --git a/libsrc/occ/occ_solid.hpp b/libsrc/occ/occ_solid.hpp
index d598de4..416c1eb 100644
--- a/libsrc/occ/occ_solid.hpp
+++ b/libsrc/occ/occ_solid.hpp
@@ -17,7 +17,11 @@ namespace netgen
: solid(TopoDS::Solid(dshape))
{ }
+#if OCC_VERSION_HEX < 0x070800
size_t GetHash() const override { return solid.HashCode(std::numeric_limits<Standard_Integer>::max()); }
+#else
+ size_t GetHash() const override { return std::hash<TopoDS_Solid>{}(solid); }
+#endif
};
}
diff --git a/libsrc/occ/occ_vertex.cpp b/libsrc/occ/occ_vertex.cpp
index 6e83c89..be8e387 100644
--- a/libsrc/occ/occ_vertex.cpp
+++ b/libsrc/occ/occ_vertex.cpp
@@ -19,6 +19,10 @@ namespace netgen
size_t OCCVertex::GetHash() const
{
+#if OCC_VERSION_HEX < 0x070800
return vertex.HashCode(std::numeric_limits<Standard_Integer>::max());
+#else
+ return std::hash<TopoDS_Shape>{}(vertex);
+#endif
}
}
diff --git a/libsrc/occ/occgeom.cpp b/libsrc/occ/occgeom.cpp
index 00ed0d0..ad58ae6 100644
--- a/libsrc/occ/occgeom.cpp
+++ b/libsrc/occ/occgeom.cpp
@@ -1717,8 +1717,12 @@ namespace netgen
/*
// enumerate shapes and archive only integers
auto my_hash = [](const TopoDS_Shape & key) {
+#if OCC_VERSION_HEX < 0x070800
auto occ_hash = key.HashCode(1<<31UL);
return std::hash<decltype(occ_hash)>()(occ_hash);
+#else
+ return std::hash<TopoDS_Shape>{}(key);
+#endif
};
*/
TopTools_IndexedMapOfShape shape_map;

View File

@ -0,0 +1,412 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index e6b3d07..f90e126 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -379,25 +379,20 @@ if (USE_OCC)
TKGeomAlgo
TKGeomBase
TKHLR
- TKIGES
TKLCAF
TKMath
TKMesh
TKOffset
TKPrim
- TKSTEP
- TKSTEP209
- TKSTEPAttr
- TKSTEPBase
- TKSTL
+ TKDESTL
TKService
TKShHealing
TKTopAlgo
TKV3d
TKVCAF
TKXCAF
- TKXDEIGES
- TKXDESTEP
+ TKDEIGES
+ TKDESTEP
TKXSBase
TKernel
)
diff --git a/libsrc/occ/Partition_Inter2d.cxx b/libsrc/occ/Partition_Inter2d.cxx
index 88b6f7d..9dc4e13 100644
--- a/libsrc/occ/Partition_Inter2d.cxx
+++ b/libsrc/occ/Partition_Inter2d.cxx
@@ -46,10 +46,9 @@
#include <TopOpeBRepDS_Transition.hxx>
#include <TopOpeBRep_EdgesIntersector.hxx>
#include <TopOpeBRep_Point2d.hxx>
-#include <TopTools_ListIteratorOfListOfShape.hxx>
#include <TopTools_ListOfShape.hxx>
-#include <TopTools_MapIteratorOfMapOfShape.hxx>
#include <TopTools_MapOfShape.hxx>
+#include <TopTools_IndexedMapOfShape.hxx>
#include <TopoDS.hxx>
#include <TopoDS_Edge.hxx>
#include <TopoDS_Vertex.hxx>
diff --git a/libsrc/occ/Partition_Inter2d.hxx b/libsrc/occ/Partition_Inter2d.hxx
index c018bac..afbdfd2 100644
--- a/libsrc/occ/Partition_Inter2d.hxx
+++ b/libsrc/occ/Partition_Inter2d.hxx
@@ -38,6 +38,7 @@
#else
#include <BRepAlgo_AsDes.hxx>
#include <TopTools_MapOfShape.hxx>
+ #include <TopTools_ListOfShape.hxx>
#endif
#ifndef _Standard_Real_HeaderFile
diff --git a/libsrc/occ/Partition_Inter3d.cxx b/libsrc/occ/Partition_Inter3d.cxx
index 3fc97b4..4b7db82 100644
--- a/libsrc/occ/Partition_Inter3d.cxx
+++ b/libsrc/occ/Partition_Inter3d.cxx
@@ -46,9 +46,9 @@
#include <TopExp_Explorer.hxx>
#include <TopOpeBRepTool_BoxSort.hxx>
-#include <TopTools_DataMapIteratorOfDataMapOfShapeListOfShape.hxx>
-#include <TopTools_ListIteratorOfListOfShape.hxx>
+#include <TopTools_DataMapOfShapeListOfShape.hxx>
#include <TopTools_ListOfShape.hxx>
+#include <TopTools_IndexedMapOfShape.hxx>
#include <TopoDS.hxx>
#include <TopoDS_Compound.hxx>
#include <TopoDS_Edge.hxx>
@@ -74,6 +74,7 @@
#include <Geom_TrimmedCurve.hxx>
#include <Precision.hxx>
#include <TColStd_MapOfInteger.hxx>
+#include <TColStd_ListOfInteger.hxx>
#include <TopOpeBRepBuild_Builder.hxx>
#include <TopOpeBRepDS_BuildTool.hxx>
#include <TopOpeBRepDS_CurveExplorer.hxx>
@@ -85,7 +86,7 @@
#include <TopOpeBRepTool_GeomTool.hxx>
#include <TopOpeBRepTool_OutCurveType.hxx>
#include <TopOpeBRep_DSFiller.hxx>
-#include <TopTools_DataMapIteratorOfDataMapOfShapeShape.hxx>
+#include <TopTools_DataMapOfShapeShape.hxx>
#include <stdio.h>
//=======================================================================
diff --git a/libsrc/occ/Partition_Loop.cxx b/libsrc/occ/Partition_Loop.cxx
index efaf77f..483a5ae 100644
--- a/libsrc/occ/Partition_Loop.cxx
+++ b/libsrc/occ/Partition_Loop.cxx
@@ -44,12 +44,11 @@
#include <Geom_Surface.hxx>
#include <TopTools_SequenceOfShape.hxx>
-#include <TopTools_ListIteratorOfListOfShape.hxx>
+#include <TopTools_ListOfShape.hxx>
#include <TopTools_MapOfShape.hxx>
-#include <TopTools_MapIteratorOfMapOfShape.hxx>
#include <TopTools_MapOfOrientedShape.hxx>
#include <TopTools_DataMapOfShapeShape.hxx>
-#include <TopTools_DataMapIteratorOfDataMapOfShapeListOfShape.hxx>
+#include <TopTools_DataMapOfShapeListOfShape.hxx>
#include <gp_Pnt.hxx>
#include <gp_Pnt2d.hxx>
diff --git a/libsrc/occ/Partition_Loop2d.cxx b/libsrc/occ/Partition_Loop2d.cxx
index 1c3d795..81f106a 100644
--- a/libsrc/occ/Partition_Loop2d.cxx
+++ b/libsrc/occ/Partition_Loop2d.cxx
@@ -34,14 +34,12 @@
#include <TColStd_SequenceOfReal.hxx>
#include <TopExp.hxx>
#include <TopExp_Explorer.hxx>
-#include <TopTools_DataMapIteratorOfDataMapOfShapeListOfShape.hxx>
-#include <TopTools_DataMapIteratorOfDataMapOfShapeShape.hxx>
+#include <TopTools_DataMapOfShapeListOfShape.hxx>
#include <TopTools_DataMapOfShapeInteger.hxx>
#include <TopTools_DataMapOfShapeReal.hxx> // V6.5
#include <TopTools_DataMapOfShapeShape.hxx>
#include <TopTools_IndexedMapOfShape.hxx>
-#include <TopTools_ListIteratorOfListOfShape.hxx>
-#include <TopTools_MapIteratorOfMapOfShape.hxx>
+#include <TopTools_ListOfShape.hxx>
#include <TopTools_MapOfOrientedShape.hxx>
#include <TopTools_MapOfShape.hxx>
#include <TopTools_SequenceOfShape.hxx>
diff --git a/libsrc/occ/Partition_Loop3d.cxx b/libsrc/occ/Partition_Loop3d.cxx
index 3e9acc3..d975ee4 100644
--- a/libsrc/occ/Partition_Loop3d.cxx
+++ b/libsrc/occ/Partition_Loop3d.cxx
@@ -17,11 +17,10 @@
#include <TopExp.hxx>
#include <BRep_Builder.hxx>
#include <TopTools_MapOfShape.hxx>
-#include <TopTools_ListIteratorOfListOfShape.hxx>
+#include <TopTools_ListOfShape.hxx>
#include <TopoDS_Shell.hxx>
#include <TopoDS_Iterator.hxx>
#include <TopoDS.hxx>
-#include <TopTools_MapIteratorOfMapOfShape.hxx>
#include <gp_Vec.hxx>
#include <gp_Pnt.hxx>
#include <Geom2d_Curve.hxx>
diff --git a/libsrc/occ/Partition_Loop3d.hxx b/libsrc/occ/Partition_Loop3d.hxx
index e171669..fe77b90 100644
--- a/libsrc/occ/Partition_Loop3d.hxx
+++ b/libsrc/occ/Partition_Loop3d.hxx
@@ -10,27 +10,17 @@
#ifndef _Partition_Loop3d_HeaderFile
#define _Partition_Loop3d_HeaderFile
-#ifndef _TopTools_ListOfShape_HeaderFile
-#include <TopTools_ListOfShape.hxx>
-#endif
-#ifndef _TopTools_IndexedDataMapOfShapeListOfShape_HeaderFile
-#include <TopTools_IndexedDataMapOfShapeListOfShape.hxx>
-#endif
-#ifndef _Standard_Boolean_HeaderFile
+#include <Standard_Version.hxx>
#include <Standard_Boolean.hxx>
-#endif
-#ifndef _Standard_Real_HeaderFile
#include <Standard_Real.hxx>
-#endif
-#ifndef _Standard_Version_HeaderFile
#include <Standard_Version.hxx>
-#endif
+#include <TopTools_ListOfShape.hxx>
+#include <TopTools_IndexedDataMapOfShapeListOfShape.hxx>
-#if OCC_VERSION_HEX < 0x070000
+#if OCC_VERSION_HEX < 0x070000 || OCC_VERSION_HEX > 0x070799
#else
#include <TopTools_ShapeMapHasher.hxx>
#include <TopTools_OrientedShapeMapHasher.hxx>
- #include <TopTools_MapOfOrientedShape.hxx>
#endif
class TopoDS_Shape;
@@ -38,6 +28,8 @@ class TopoDS_Shape;
#if OCC_VERSION_HEX < 0x070000
class TopTools_ListOfShape;
class TopTools_MapOfOrientedShape;
+#else
+#include <TopTools_MapOfOrientedShape.hxx>
#endif
class TopoDS_Edge;
diff --git a/libsrc/occ/Partition_Spliter.cxx b/libsrc/occ/Partition_Spliter.cxx
index 7a1d913..7a0a87c 100644
--- a/libsrc/occ/Partition_Spliter.cxx
+++ b/libsrc/occ/Partition_Spliter.cxx
@@ -43,13 +43,11 @@
#include <TopExp.hxx>
#include <TopExp_Explorer.hxx>
-#include <TopTools_DataMapIteratorOfDataMapOfShapeListOfShape.hxx>
#include <TopTools_DataMapOfShapeListOfShape.hxx>
#include <TopTools_IndexedDataMapOfShapeListOfShape.hxx>
#include <TopTools_IndexedMapOfShape.hxx>
-#include <TopTools_ListIteratorOfListOfShape.hxx>
#include <TopTools_ListOfShape.hxx>
-#include <TopTools_MapIteratorOfMapOfShape.hxx>
+#include <TopTools_MapOfShape.hxx>
#include <TopTools_SequenceOfShape.hxx>
#include <Geom2d_Curve.hxx>
diff --git a/libsrc/occ/occ_edge.cpp b/libsrc/occ/occ_edge.cpp
index 4805bb1..e8b272f 100644
--- a/libsrc/occ/occ_edge.cpp
+++ b/libsrc/occ/occ_edge.cpp
@@ -55,7 +55,11 @@ namespace netgen
size_t OCCEdge::GetHash() const
{
+#if OCC_VERSION_HEX < 0x070800
return edge.HashCode(std::numeric_limits<Standard_Integer>::max());
+#else
+ return std::hash<TopoDS_Shape>{}(edge);
+#endif
}
void OCCEdge::ProjectPoint(Point<3>& p, EdgePointGeomInfo* gi) const
diff --git a/libsrc/occ/occ_face.cpp b/libsrc/occ/occ_face.cpp
index 239982a..ec6dee3 100644
--- a/libsrc/occ/occ_face.cpp
+++ b/libsrc/occ/occ_face.cpp
@@ -32,7 +32,11 @@ namespace netgen
size_t OCCFace::GetHash() const
{
+#if OCC_VERSION_HEX < 0x070800
return face.HashCode(std::numeric_limits<Standard_Integer>::max());
+#else
+ return std::hash<TopoDS_Shape>{}(face);
+#endif
}
Point<3> OCCFace::GetCenter() const
diff --git a/libsrc/occ/occ_solid.hpp b/libsrc/occ/occ_solid.hpp
index d598de4..416c1eb 100644
--- a/libsrc/occ/occ_solid.hpp
+++ b/libsrc/occ/occ_solid.hpp
@@ -17,7 +17,11 @@ namespace netgen
: solid(TopoDS::Solid(dshape))
{ }
+#if OCC_VERSION_HEX < 0x070800
size_t GetHash() const override { return solid.HashCode(std::numeric_limits<Standard_Integer>::max()); }
+#else
+ size_t GetHash() const override { return std::hash<TopoDS_Solid>{}(solid); }
+#endif
};
}
diff --git a/libsrc/occ/occ_vertex.cpp b/libsrc/occ/occ_vertex.cpp
index 6e83c89..982992a 100644
--- a/libsrc/occ/occ_vertex.cpp
+++ b/libsrc/occ/occ_vertex.cpp
@@ -19,6 +19,10 @@ namespace netgen
size_t OCCVertex::GetHash() const
{
+#if OCC_VERSION_HEX < 0x070800
return vertex.HashCode(std::numeric_limits<Standard_Integer>::max());
+#else
+ return std::hash<TopoDS_Shape>{}(vertex);
+#endif
}
}
diff --git a/libsrc/occ/occgeom.cpp b/libsrc/occ/occgeom.cpp
index 00ed0d0..dbbe921 100644
--- a/libsrc/occ/occgeom.cpp
+++ b/libsrc/occ/occgeom.cpp
@@ -46,6 +46,7 @@
#include <StepRepr_RepresentationItem.hxx>
#include <StlAPI_Writer.hxx>
#include <TopoDS_Shape.hxx>
+#include <TDF_LabelSequence.hxx>
#include <TransferBRep.hxx>
#include <Transfer_FinderProcess.hxx>
#include <Transfer_TransientProcess.hxx>
@@ -54,6 +55,7 @@
#include <XCAFDoc_DocumentTool.hxx>
#include <XCAFDoc_ShapeTool.hxx>
#include <XCAFPrs.hxx>
+#include <XCAFPrs_IndexedDataMapOfShapeStyle.hxx>
#include <XCAFPrs_Style.hxx>
#include <XSControl_TransferReader.hxx>
#include <XSControl_WorkSession.hxx>
@@ -1717,8 +1719,12 @@ namespace netgen
/*
// enumerate shapes and archive only integers
auto my_hash = [](const TopoDS_Shape & key) {
+#if OCC_VERSION_HEX < 0x070800
auto occ_hash = key.HashCode(1<<31UL);
return std::hash<decltype(occ_hash)>()(occ_hash);
+#else
+ return std::hash<TopoDS_Shape>{}(key);
+#endif
};
*/
TopTools_IndexedMapOfShape shape_map;
diff --git a/libsrc/occ/occgeom.hpp b/libsrc/occ/occgeom.hpp
index c7118ce..e098f14 100644
--- a/libsrc/occ/occgeom.hpp
+++ b/libsrc/occ/occgeom.hpp
@@ -24,11 +24,13 @@
#include <StepBasic_MeasureValueMember.hxx>
#include <StepRepr_CompoundRepresentationItem.hxx>
#include <StepRepr_IntegerRepresentationItem.hxx>
+#include <StepRepr_HArray1OfRepresentationItem.hxx>
#include <StepRepr_ValueRepresentationItem.hxx>
#include <TCollection_HAsciiString.hxx>
#include <TDocStd_Document.hxx>
#include <TopoDS.hxx>
#include <TopoDS_Shape.hxx>
+#include <TopTools_MapOfShape.hxx>
#include <Transfer_FinderProcess.hxx>
#if OCC_VERSION_MAJOR>=7 && OCC_VERSION_MINOR>=4
diff --git a/libsrc/occ/python_occ.cpp b/libsrc/occ/python_occ.cpp
index 4808957..3f93834 100644
--- a/libsrc/occ/python_occ.cpp
+++ b/libsrc/occ/python_occ.cpp
@@ -70,10 +70,9 @@ DLL_HEADER void ExportNgOCC(py::module &m)
// suppress info messages from occ (like statistics on Transfer)
Message_Gravity aGravity = Message_Alarm;
- for (Message_SequenceOfPrinters::Iterator aPrinterIter (Message::DefaultMessenger()->Printers());
- aPrinterIter.More(); aPrinterIter.Next())
+ for (const auto& aPrinter : Message::DefaultMessenger()->Printers())
{
- aPrinterIter.Value()->SetTraceLevel (aGravity);
+ aPrinter->SetTraceLevel (aGravity);
}
ExportNgOCCBasic(m);
@@ -85,7 +84,11 @@ DLL_HEADER void ExportNgOCC(py::module &m)
try {
if(p) std::rethrow_exception(p);
} catch (const Standard_Failure& e) {
+#if OCC_VERSION_HEX < 0x080000
exc((string(e.DynamicType()->Name()) + ": " + e.GetMessageString()).c_str());
+#else
+ exc((string(e.ExceptionType()) + ": " + e.what()).c_str());
+#endif
}
});
diff --git a/libsrc/occ/python_occ_shapes.cpp b/libsrc/occ/python_occ_shapes.cpp
index bd265ca..4c64735 100644
--- a/libsrc/occ/python_occ_shapes.cpp
+++ b/libsrc/occ/python_occ_shapes.cpp
@@ -13,6 +13,16 @@
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
+#include <TColgp_Array1OfPnt2d.hxx>
+#include <TColgp_Array1OfVec2d.hxx>
+#include <TColgp_HArray1OfPnt2d.hxx>
+#include <TColStd_HArray1OfBoolean.hxx>
+#include <TColStd_Array1OfReal.hxx>
+#include <TColStd_Array1OfInteger.hxx>
+#include <TColgp_HArray1OfPnt.hxx>
+#include <TColgp_Array2OfPnt.hxx>
+#include <TColgp_Array1OfVec.hxx>
+#include <TColgp_Array1OfPnt.hxx>
#include <BOPAlgo_Builder.hxx>
#include <BOPTools_AlgoTools.hxx>
#include <BRepAlgoAPI_Common.hxx>
@@ -76,6 +86,8 @@
#include <gp_Ax2d.hxx>
#include <gp_Pln.hxx>
#include <gp_Trsf.hxx>
+#include <TopTools_HSequenceOfShape.hxx>
+#include <TopTools_ListOfShape.hxx>
#pragma clang diagnostic pop
@@ -2221,9 +2233,10 @@ tangents : Dict[int, gp_Vec2d]
m.def("BSplineCurve", [](std::vector<gp_Pnt> vpoles, int degree) {
// not yet working ????
- TColgp_Array1OfPnt poles(0, vpoles.size()-1);
- TColStd_Array1OfReal knots(0, vpoles.size()+degree);
- TColStd_Array1OfInteger mult(0, vpoles.size()+degree);
+ // Avoid C2666 overload ambiguity in OCCT collection constructors.
+ TColgp_Array1OfPnt poles(0, static_cast<Standard_Integer>(vpoles.size())-1);
+ TColStd_Array1OfReal knots(0, static_cast<Standard_Integer>(vpoles.size())+degree);
+ TColStd_Array1OfInteger mult(0, static_cast<Standard_Integer>(vpoles.size())+degree);
// int cnt = 0;
for (int i = 0; i < vpoles.size(); i++)
@@ -2243,7 +2256,8 @@ tangents : Dict[int, gp_Vec2d]
});
m.def("BezierCurve", [](std::vector<gp_Pnt> vpoles) {
- TColgp_Array1OfPnt poles(0, vpoles.size()-1);
+ // Avoid C2666 overload ambiguity in OCCT collection constructors.
+ TColgp_Array1OfPnt poles(0, static_cast<Standard_Integer>(vpoles.size())-1);
for (int i = 0; i < vpoles.size(); i++)
poles.SetValue(i, vpoles[i]);

View File

@ -12,7 +12,7 @@ vcpkg_from_github(
cgns-scoped-enum.patch
downstream-fixes.patch
add_filesystem.patch
occ-78.patch
occt-compat.patch
142.diff
cross-build.patch
)

View File

@ -1,7 +1,7 @@
{
"name": "netgen",
"version": "6.2.2401",
"port-version": 3,
"port-version": 4,
"description": "NETGEN is an automatic 3d tetrahedral mesh generator. It accepts input from constructive solid geometry (CSG) or boundary representation (BRep) from STL file format. The connection to a geometry kernel allows the handling of IGES and STEP files. NETGEN contains modules for mesh optimization and hierarchical mesh refinement.",
"homepage": "https://ngsolve.org/",
"license": "LGPL-2.1-or-later",

View File

@ -947,18 +947,6 @@ nana:x64-linux=fail
nanodbc:x64-linux=skip
netcdf-cxx4:arm64-windows-static-md=fail
netcdf-cxx4:x64-windows-static-md=fail
netgen:arm64-android=fail
netgen:arm64-osx=fail
netgen:arm64-windows-static-md=fail
netgen:arm64-windows=fail
netgen:x64-android=fail
netgen:x64-linux=fail
netgen:x64-windows-release=fail
netgen:x64-windows-release=fail
netgen:x64-windows-static-md=fail
netgen:x64-windows-static=fail
netgen:x64-windows-static=fail
netgen:x64-windows=fail
nethost:arm64-linux=fail
ngspice:x64-android=fail
ngspice:x64-windows-static=fail

View File

@ -7006,7 +7006,7 @@
},
"netgen": {
"baseline": "6.2.2401",
"port-version": 3
"port-version": 4
},
"nethost": {
"baseline": "8.0.3",

View File

@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "075e59fc127c1f9b84b5c2fb85c7a9200a5ebc9c",
"version": "6.2.2401",
"port-version": 4
},
{
"git-tree": "9c444be4d2a61cb67f2052719d87e4c9f1550d14",
"version": "6.2.2401",