File tree Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Original file line number Diff line number Diff line change 156
156
157
157
from OCP .TopExp import TopExp
158
158
159
- from OCP .ShapeFix import ShapeFix_Shape , ShapeFix_Solid
159
+ from OCP .ShapeFix import ShapeFix_Shape , ShapeFix_Solid , ShapeFix_Face
160
160
161
161
from OCP .STEPControl import STEPControl_Writer , STEPControl_AsIs
162
162
@@ -2110,9 +2110,13 @@ def makeFromWires(
2110
2110
if not face_builder .IsDone ():
2111
2111
raise ValueError (f"Cannot build face(s): { face_builder .Error ()} " )
2112
2112
2113
- face = face_builder .Shape ()
2113
+ face = face_builder .Face ()
2114
2114
2115
- return cls (face ).fix ()
2115
+ sf = ShapeFix_Face (face )
2116
+ sf .FixOrientation ()
2117
+ sf .Perform ()
2118
+
2119
+ return cls (sf .Result ())
2116
2120
2117
2121
@classmethod
2118
2122
def makeSplineApprox (
@@ -2127,7 +2131,7 @@ def makeSplineApprox(
2127
2131
Approximate a spline surface through the provided points.
2128
2132
2129
2133
:param points: a 2D list of Vectors that represent the points
2130
- :param tol: tolerance of the algorithm (consult OCC documentation).
2134
+ :param tol: tolerance of the algorithm (consult OCC documentation).
2131
2135
:param smoothing: optional tuple of 3 weights use for variational smoothing (default: None)
2132
2136
:param minDeg: minimum spline degree. Enforced only when smothing is None (default: 1)
2133
2137
:param maxDeg: maximum spline degree (default: 6)
You can’t perform that action at this time.
0 commit comments