Skip to content

Commit

Permalink
OCC: mesh edge hausd final
Browse files Browse the repository at this point in the history
  • Loading branch information
benoit128 committed Dec 13, 2024
1 parent eabeb4c commit a861098
Show file tree
Hide file tree
Showing 2 changed files with 153 additions and 612 deletions.
7 changes: 4 additions & 3 deletions Cassiopee/CPlot/apps/tkCADFix.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ def readCAD(event=None):
[hmin, hmax, hausd] = OCC.getCADcontainer(CTK.t)
if hmax is None or (hmax < 0 and hausd < 0):
(hmax,hmin,hausd) = OCC.occ.analyseEdges(hook)
OCC._setCADcontainer(CTK.t, fileName, fileFmt, hmax, hausd)
OCC._setCADcontainer(CTK.t, fileName, fileFmt, hmin, hmax, hausd)
CTK.CADHOOK = hook
# remesh and redisplay
CTK.setCursor(2, WIDGETS['frame'])
Expand Down Expand Up @@ -410,15 +410,16 @@ def checkWatertight(event=None):
if CAD is not None:
hmax = Internal.getNodeFromName1(CAD, 'hmax')
hmax = Internal.getValue(hmax)
tol = hmax/10.
tol = hmax/100.

CTK.t = C.addBase2PyTree(CTK.t, 'LEAKS', 1)
p = Internal.getNodeFromName1(CTK.t, 'LEAKS')
gnob = C.getNobOfBase(p, CTK.t)

f = Internal.getZones(b)
f = G.zip(f, tol)
f = T.join(f)
f = G.close(f, tol)
#f = G.close(f, tol)
ef = T.splitConnexity(f)
VARS[6].set('Components: %d'%(len(ef)))

Expand Down
Loading

0 comments on commit a861098

Please sign in to comment.