From: Paul RASCLE Date: Thu, 27 Aug 2020 14:14:30 +0000 (+0200) Subject: Python function mergePolylines X-Git-Tag: SH_V2_2_0~67 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=cff87bac4c600579461e6c8392a4b50fa679d284;p=modules%2Fhydro.git Python function mergePolylines --- diff --git a/src/HYDROTools/hydroGeoMeshUtils.py b/src/HYDROTools/hydroGeoMeshUtils.py index 18df35eb..990dd9c4 100644 --- a/src/HYDROTools/hydroGeoMeshUtils.py +++ b/src/HYDROTools/hydroGeoMeshUtils.py @@ -74,3 +74,11 @@ def createImmersibleZone(document, imzName, polyLine, bathy, isImmersible, displ imz.SetIsSubmersible(isImmersible) imz.Update() return imz + +def mergePolylines(document, polyName, polyLines, isConnectedBySegment = False, tolerance = 1.E-3): + """ + """ + op=HYDROData_PolylineOperator() + op.Merge(document, polyName, polyLines, isConnectedBySegment, tolerance) + shape = document.FindObjectByName(polyName) + return shape