Back to index

salome-geom  6.5.0
Functions
Repairing Operations
Transforming geometrical objects
Collaboration diagram for Repairing Operations:

Functions

def geompyDC.geompyDC.ChangeOrientation
 Reverses an orientation the given shape.
def geompyDC.geompyDC.OrientationChange
 See ChangeOrientation() method for details.
def geompyDC.geompyDC.ProcessShape
 Apply a sequence of Shape Healing operators to the given object.
def geompyDC.geompyDC.SuppressFaces
 Remove faces from the given object (shape).
def geompyDC.geompyDC.MakeSewing
 Sewing of some shapes into single shape.
def geompyDC.geompyDC.Sew
 Sewing of the given object.
def geompyDC.geompyDC.SuppressInternalWires
 Remove internal wires and edges from the given object (face).
def geompyDC.geompyDC.SuppressHoles
 Remove internal closed contours (holes) from the given object.
def geompyDC.geompyDC.CloseContour
 Close an open wire.
def geompyDC.geompyDC.DivideEdge
 Addition of a point to a given edge object.
def geompyDC.geompyDC.ChangeOrientationShell
 Change orientation of the given object.
def geompyDC.geompyDC.ChangeOrientationShellCopy
 Change orientation of the given object.
def geompyDC.geompyDC.LimitTolerance
 Try to limit tolerance of the given object by value theTolerance.
def geompyDC.geompyDC.GetFreeBoundary
 Get a list of wires (wrapped in GEOM.GEOM_Object-s), that constitute a free boundary of the given shape.
def geompyDC.geompyDC.MakeGlueFaces
 Replace coincident faces in theShape by one face.
def geompyDC.geompyDC.GetGlueFaces
 Find coincident faces in theShape for possible gluing.
def geompyDC.geompyDC.MakeGlueFacesByList
 Replace coincident faces in theShape by one face in compliance with given list of faces.
def geompyDC.geompyDC.MakeGlueEdges
 Replace coincident edges in theShape by one edge.
def geompyDC.geompyDC.GetGlueEdges
 Find coincident edges in theShape for possible gluing.
def geompyDC.geompyDC.MakeGlueEdgesByList
 Replace coincident edges in theShape by one edge in compliance with given list of edges.

Function Documentation

def geompyDC.geompyDC.ChangeOrientation (   self,
  theShape 
)

Reverses an orientation the given shape.

Parameters:
theShapeShape to be reversed.
Returns:
The reversed copy of theShape.

Example

Reverses an orientation the given shape.

Parameters:
    theShape Shape to be reversed.

Returns:   
    The reversed copy of theShape.

Definition at line 3118 of file geompyDC.py.

03118 
03119         def ChangeOrientation(self,theShape):
03120             """
03121             Reverses an orientation the given shape.
03122 
03123             Parameters:
03124                 theShape Shape to be reversed.
03125 
03126             Returns:   
03127                 The reversed copy of theShape.
03128             """
03129             # Example: see GEOM_TestAll.py
03130             anObj = self.ShapesOp.ChangeOrientation(theShape)
03131             RaiseIfFailed("ChangeOrientation", self.ShapesOp)
03132             return anObj

Here is the call graph for this function:

Here is the caller graph for this function:

def geompyDC.geompyDC.ChangeOrientationShell (   self,
  theObject 
)

Change orientation of the given object.

Updates given shape.

Parameters:
theObjectShape to be processed.
Returns:
Updated theObject

Example

Change orientation of the given object. Updates given shape.

Parameters: 
    theObject Shape to be processed.

Returns:  
    Updated theObject

Definition at line 4615 of file geompyDC.py.

04615 
04616         def ChangeOrientationShell(self,theObject):
04617             """
04618             Change orientation of the given object. Updates given shape.
04619 
04620             Parameters: 
04621                 theObject Shape to be processed.
04622 
04623             Returns:  
04624                 Updated theObject
04625             """
04626             theObject = self.HealOp.ChangeOrientation(theObject)
04627             RaiseIfFailed("ChangeOrientation", self.HealOp)
04628             pass

Here is the call graph for this function:

def geompyDC.geompyDC.ChangeOrientationShellCopy (   self,
  theObject 
)

Change orientation of the given object.

Parameters:
theObjectShape to be processed.
Returns:
New GEOM.GEOM_Object, containing processed shape.

Example

Change orientation of the given object.

Parameters:
    theObject Shape to be processed.

Returns:   
    New GEOM.GEOM_Object, containing processed shape.

Definition at line 4634 of file geompyDC.py.

04634 
04635         def ChangeOrientationShellCopy(self, theObject):
04636             """
04637             Change orientation of the given object.
04638 
04639             Parameters:
04640                 theObject Shape to be processed.
04641 
04642             Returns:   
04643                 New GEOM.GEOM_Object, containing processed shape.
04644             """
04645             anObj = self.HealOp.ChangeOrientationCopy(theObject)
04646             RaiseIfFailed("ChangeOrientationCopy", self.HealOp)
04647             return anObj

Here is the call graph for this function:

def geompyDC.geompyDC.CloseContour (   self,
  theObject,
  theWires,
  isCommonVertex 
)

Close an open wire.

Parameters:
theObjectShape to be processed.
theWiresIndexes of edge(s) and wire(s) to be closed within theObject's shape, if [ ], then theObject itself is a wire.
isCommonVertexIf True : closure by creation of a common vertex, If False : closure by creation of an edge between ends.
Returns:
New GEOM.GEOM_Object, containing processed shape.

Example

Close an open wire.

Parameters: 
    theObject Shape to be processed.
    theWires Indexes of edge(s) and wire(s) to be closed within theObject's shape,
 if [ ], then theObject itself is a wire.
    isCommonVertex If True  : closure by creation of a common vertex,
       If False : closure by creation of an edge between ends.

Returns:                      
    New GEOM.GEOM_Object, containing processed shape. 

Definition at line 4557 of file geompyDC.py.

04557 
04558         def CloseContour(self,theObject, theWires, isCommonVertex):
04559             """
04560             Close an open wire.
04561 
04562             Parameters: 
04563                 theObject Shape to be processed.
04564                 theWires Indexes of edge(s) and wire(s) to be closed within theObject's shape,
04565                          if [ ], then theObject itself is a wire.
04566                 isCommonVertex If True  : closure by creation of a common vertex,
04567                                If False : closure by creation of an edge between ends.
04568 
04569             Returns:                      
04570                 New GEOM.GEOM_Object, containing processed shape. 
04571             """
04572             # Example: see GEOM_TestHealing.py
04573             anObj = self.HealOp.CloseContour(theObject, theWires, isCommonVertex)
04574             RaiseIfFailed("CloseContour", self.HealOp)
04575             return anObj

Here is the call graph for this function:

def geompyDC.geompyDC.DivideEdge (   self,
  theObject,
  theEdgeIndex,
  theValue,
  isByParameter 
)

Addition of a point to a given edge object.

Parameters:
theObjectShape to be processed.
theEdgeIndexIndex of edge to be divided within theObject's shape, if -1, then theObject itself is the edge.
theValueValue of parameter on edge or length parameter, depending on isByParameter.
isByParameterIf TRUE : theValue is treated as a curve parameter [0..1],
if FALSE : theValue is treated as a length parameter [0..1]
Returns:
New GEOM.GEOM_Object, containing processed shape.

Example

Addition of a point to a given edge object.

Parameters: 
    theObject Shape to be processed.
    theEdgeIndex Index of edge to be divided within theObject's shape,
     if -1, then theObject itself is the edge.
    theValue Value of parameter on edge or length parameter,
 depending on isByParameter.
    isByParameter If TRUE :  theValue is treated as a curve parameter [0..1],
      if FALSE : theValue is treated as a length parameter [0..1]

Returns:  
    New GEOM.GEOM_Object, containing processed shape.

Definition at line 4587 of file geompyDC.py.

04587 
04588         def DivideEdge(self,theObject, theEdgeIndex, theValue, isByParameter):
04589             """
04590             Addition of a point to a given edge object.
04591 
04592             Parameters: 
04593                 theObject Shape to be processed.
04594                 theEdgeIndex Index of edge to be divided within theObject's shape,
04595                              if -1, then theObject itself is the edge.
04596                 theValue Value of parameter on edge or length parameter,
04597                          depending on isByParameter.
04598                 isByParameter If TRUE :  theValue is treated as a curve parameter [0..1],
04599                               if FALSE : theValue is treated as a length parameter [0..1]
04600 
04601             Returns:  
04602                 New GEOM.GEOM_Object, containing processed shape.
04603             """
04604             # Example: see GEOM_TestHealing.py
04605             theEdgeIndex,theValue,isByParameter,Parameters = ParseParameters(theEdgeIndex,theValue,isByParameter)
04606             anObj = self.HealOp.DivideEdge(theObject, theEdgeIndex, theValue, isByParameter)
04607             RaiseIfFailed("DivideEdge", self.HealOp)
04608             anObj.SetParameters(Parameters)
04609             return anObj

Here is the call graph for this function:

def geompyDC.geompyDC.GetFreeBoundary (   self,
  theObject 
)

Get a list of wires (wrapped in GEOM.GEOM_Object-s), that constitute a free boundary of the given shape.

Parameters:
theObjectShape to get free boundary of.
Returns:
[status, theClosedWires, theOpenWires]
status: FALSE, if an error(s) occured during the method execution.
theClosedWires: Closed wires on the free boundary of the given shape.
theOpenWires: Open wires on the free boundary of the given shape.

Example

Get a list of wires (wrapped in GEOM.GEOM_Object-s),
that constitute a free boundary of the given shape.

Parameters:
    theObject Shape to get free boundary of.

Returns: 
    [status, theClosedWires, theOpenWires]
     status: FALSE, if an error(s) occured during the method execution.
     theClosedWires: Closed wires on the free boundary of the given shape.
     theOpenWires: Open wires on the free boundary of the given shape.

Definition at line 4678 of file geompyDC.py.

04678 
04679         def GetFreeBoundary(self, theObject):
04680             """
04681             Get a list of wires (wrapped in GEOM.GEOM_Object-s),
04682             that constitute a free boundary of the given shape.
04683 
04684             Parameters:
04685                 theObject Shape to get free boundary of.
04686 
04687             Returns: 
04688                 [status, theClosedWires, theOpenWires]
04689                  status: FALSE, if an error(s) occured during the method execution.
04690                  theClosedWires: Closed wires on the free boundary of the given shape.
04691                  theOpenWires: Open wires on the free boundary of the given shape.
04692             """
04693             # Example: see GEOM_TestHealing.py
04694             anObj = self.HealOp.GetFreeBoundary(theObject)
04695             RaiseIfFailed("GetFreeBoundary", self.HealOp)
04696             return anObj

Here is the call graph for this function:

def geompyDC.geompyDC.GetGlueEdges (   self,
  theShape,
  theTolerance 
)

Find coincident edges in theShape for possible gluing.

Parameters:
theShapeInitial shape.
theToleranceMaximum distance between edges, which can be considered as coincident.
Returns:
GEOM.ListOfGO

Example

Find coincident edges in theShape for possible gluing.

Parameters:
    theShape Initial shape.
    theTolerance Maximum distance between edges,
     which can be considered as coincident.

Returns:                         
    GEOM.ListOfGO

Definition at line 4822 of file geompyDC.py.

04822 
04823         def GetGlueEdges(self, theShape, theTolerance):
04824             """
04825             Find coincident edges in theShape for possible gluing.
04826 
04827             Parameters:
04828                 theShape Initial shape.
04829                 theTolerance Maximum distance between edges,
04830                              which can be considered as coincident.
04831 
04832             Returns:                         
04833                 GEOM.ListOfGO
04834             """
04835             anObj = self.ShapesOp.GetGlueEdges(theShape, theTolerance)
04836             RaiseIfFailed("GetGlueEdges", self.ShapesOp)
04837             return anObj

Here is the call graph for this function:

def geompyDC.geompyDC.GetGlueFaces (   self,
  theShape,
  theTolerance 
)

Find coincident faces in theShape for possible gluing.

Parameters:
theShapeInitial shape.
theToleranceMaximum distance between faces, which can be considered as coincident.
Returns:
GEOM.ListOfGO

Example

Find coincident faces in theShape for possible gluing.

Parameters:
    theShape Initial shape.
    theTolerance Maximum distance between faces,
     which can be considered as coincident.

Returns:                    
    GEOM.ListOfGO

Definition at line 4733 of file geompyDC.py.

04733 
04734         def GetGlueFaces(self, theShape, theTolerance):
04735             """
04736             Find coincident faces in theShape for possible gluing.
04737 
04738             Parameters:
04739                 theShape Initial shape.
04740                 theTolerance Maximum distance between faces,
04741                              which can be considered as coincident.
04742 
04743             Returns:                    
04744                 GEOM.ListOfGO
04745             """
04746             anObj = self.ShapesOp.GetGlueFaces(theShape, theTolerance)
04747             RaiseIfFailed("GetGlueFaces", self.ShapesOp)
04748             return anObj

Here is the call graph for this function:

def geompyDC.geompyDC.LimitTolerance (   self,
  theObject,
  theTolerance = 1e-07 
)

Try to limit tolerance of the given object by value theTolerance.

Parameters:
theObjectShape to be processed.
theToleranceRequired tolerance value.
Returns:
New GEOM.GEOM_Object, containing processed shape.

Example

Try to limit tolerance of the given object by value theTolerance.

Parameters:
    theObject Shape to be processed.
    theTolerance Required tolerance value.

Returns:   
    New GEOM.GEOM_Object, containing processed shape.

Definition at line 4654 of file geompyDC.py.

04654 
04655         def LimitTolerance(self, theObject, theTolerance = 1e-07):
04656             """
04657             Try to limit tolerance of the given object by value theTolerance.
04658 
04659             Parameters:
04660                 theObject Shape to be processed.
04661                 theTolerance Required tolerance value.
04662 
04663             Returns:   
04664                 New GEOM.GEOM_Object, containing processed shape.
04665             """
04666             anObj = self.HealOp.LimitTolerance(theObject, theTolerance)
04667             RaiseIfFailed("LimitTolerance", self.HealOp)
04668             return anObj

Here is the call graph for this function:

def geompyDC.geompyDC.MakeGlueEdges (   self,
  theShape,
  theTolerance 
)

Replace coincident edges in theShape by one edge.

Parameters:
theShapeInitial shape.
theToleranceMaximum distance between edges, which can be considered as coincident.
Returns:
New GEOM.GEOM_Object, containing a copy of theShape without coincident edges.

Example

Replace coincident edges in theShape by one edge.

Parameters:
    theShape Initial shape.
    theTolerance Maximum distance between edges, which can be considered as coincident.

Returns:    
    New GEOM.GEOM_Object, containing a copy of theShape without coincident edges.

Definition at line 4797 of file geompyDC.py.

04797 
04798         def MakeGlueEdges(self, theShape, theTolerance):
04799             """
04800             Replace coincident edges in theShape by one edge.
04801 
04802             Parameters:
04803                 theShape Initial shape.
04804                 theTolerance Maximum distance between edges, which can be considered as coincident.
04805 
04806             Returns:    
04807                 New GEOM.GEOM_Object, containing a copy of theShape without coincident edges.
04808             """
04809             theTolerance,Parameters = ParseParameters(theTolerance)
04810             anObj = self.ShapesOp.MakeGlueEdges(theShape, theTolerance)
04811             if anObj is None:
04812                 raise RuntimeError, "MakeGlueEdges : " + self.ShapesOp.GetErrorCode()
04813             anObj.SetParameters(Parameters)
04814             return anObj

Here is the call graph for this function:

def geompyDC.geompyDC.MakeGlueEdgesByList (   self,
  theShape,
  theTolerance,
  theEdges 
)

Replace coincident edges in theShape by one edge in compliance with given list of edges.

Parameters:
theShapeInitial shape.
theToleranceMaximum distance between edges, which can be considered as coincident.
theEdgesList of edges for gluing.
Returns:
New GEOM.GEOM_Object, containing a copy of theShape without some edges.

Example

Replace coincident edges in theShape by one edge
in compliance with given list of edges.

Parameters:
    theShape Initial shape.
    theTolerance Maximum distance between edges,
     which can be considered as coincident.
    theEdges List of edges for gluing.

Returns:  
    New GEOM.GEOM_Object, containing a copy of theShape
    without some edges.

Definition at line 4848 of file geompyDC.py.

04848 
04849         def MakeGlueEdgesByList(self, theShape, theTolerance, theEdges):
04850             """
04851             Replace coincident edges in theShape by one edge
04852             in compliance with given list of edges.
04853 
04854             Parameters:
04855                 theShape Initial shape.
04856                 theTolerance Maximum distance between edges,
04857                              which can be considered as coincident.
04858                 theEdges List of edges for gluing.
04859 
04860             Returns:  
04861                 New GEOM.GEOM_Object, containing a copy of theShape
04862                 without some edges.
04863             """
04864             anObj = self.ShapesOp.MakeGlueEdgesByList(theShape, theTolerance, theEdges)
04865             if anObj is None:
04866                 raise RuntimeError, "MakeGlueEdgesByList : " + self.ShapesOp.GetErrorCode()
04867             return anObj

def geompyDC.geompyDC.MakeGlueFaces (   self,
  theShape,
  theTolerance,
  doKeepNonSolids = True 
)

Replace coincident faces in theShape by one face.

Parameters:
theShapeInitial shape.
theToleranceMaximum distance between faces, which can be considered as coincident.
doKeepNonSolidsIf FALSE, only solids will present in the result, otherwise all initial shapes.
Returns:
New GEOM.GEOM_Object, containing a copy of theShape without coincident faces.

Example

Replace coincident faces in theShape by one face.

Parameters:
    theShape Initial shape.
    theTolerance Maximum distance between faces, which can be considered as coincident.
    doKeepNonSolids If FALSE, only solids will present in the result,
        otherwise all initial shapes.

Returns:
    New GEOM.GEOM_Object, containing a copy of theShape without coincident faces.

Definition at line 4705 of file geompyDC.py.

04705 
04706         def MakeGlueFaces(self, theShape, theTolerance, doKeepNonSolids=True):
04707             """
04708             Replace coincident faces in theShape by one face.
04709 
04710             Parameters:
04711                 theShape Initial shape.
04712                 theTolerance Maximum distance between faces, which can be considered as coincident.
04713                 doKeepNonSolids If FALSE, only solids will present in the result,
04714                                 otherwise all initial shapes.
04715 
04716             Returns:
04717                 New GEOM.GEOM_Object, containing a copy of theShape without coincident faces.
04718             """
04719             # Example: see GEOM_Spanner.py
04720             theTolerance,Parameters = ParseParameters(theTolerance)
04721             anObj = self.ShapesOp.MakeGlueFaces(theShape, theTolerance, doKeepNonSolids)
04722             if anObj is None:
04723                 raise RuntimeError, "MakeGlueFaces : " + self.ShapesOp.GetErrorCode()
04724             anObj.SetParameters(Parameters)
04725             return anObj

Here is the call graph for this function:

def geompyDC.geompyDC.MakeGlueFacesByList (   self,
  theShape,
  theTolerance,
  theFaces,
  doKeepNonSolids = True,
  doGlueAllEdges = True 
)

Replace coincident faces in theShape by one face in compliance with given list of faces.

Parameters:
theShapeInitial shape.
theToleranceMaximum distance between faces, which can be considered as coincident.
theFacesList of faces for gluing.
doKeepNonSolidsIf FALSE, only solids will present in the result, otherwise all initial shapes.
doGlueAllEdgesIf TRUE, all coincident edges of theShape will be glued, otherwise only the edges, belonging to theFaces.
Returns:
New GEOM.GEOM_Object, containing a copy of theShape without some faces.

Example

Replace coincident faces in theShape by one face
in compliance with given list of faces

Parameters:
    theShape Initial shape.
    theTolerance Maximum distance between faces,
     which can be considered as coincident.
    theFaces List of faces for gluing.
    doKeepNonSolids If FALSE, only solids will present in the result,
        otherwise all initial shapes.
    doGlueAllEdges If TRUE, all coincident edges of theShape
       will be glued, otherwise only the edges,
       belonging to theFaces.

Returns:
    New GEOM.GEOM_Object, containing a copy of theShape
        without some faces.

Definition at line 4765 of file geompyDC.py.

04765 
04766                                 doKeepNonSolids=True, doGlueAllEdges=True):
04767             """
04768             Replace coincident faces in theShape by one face
04769             in compliance with given list of faces
04770 
04771             Parameters:
04772                 theShape Initial shape.
04773                 theTolerance Maximum distance between faces,
04774                              which can be considered as coincident.
04775                 theFaces List of faces for gluing.
04776                 doKeepNonSolids If FALSE, only solids will present in the result,
04777                                 otherwise all initial shapes.
04778                 doGlueAllEdges If TRUE, all coincident edges of theShape
04779                                will be glued, otherwise only the edges,
04780                                belonging to theFaces.
04781 
04782             Returns:
04783                 New GEOM.GEOM_Object, containing a copy of theShape
04784                     without some faces.
04785             """
04786             anObj = self.ShapesOp.MakeGlueFacesByList(theShape, theTolerance, theFaces,
04787                                                       doKeepNonSolids, doGlueAllEdges)
04788             if anObj is None:
04789                 raise RuntimeError, "MakeGlueFacesByList : " + self.ShapesOp.GetErrorCode()
04790             return anObj

Here is the caller graph for this function:

def geompyDC.geompyDC.MakeSewing (   self,
  ListShape,
  theTolerance 
)

Sewing of some shapes into single shape.

Parameters:
ListShapeShapes to be processed.
theToleranceRequired tolerance value.
Returns:
New GEOM.GEOM_Object, containing processed shape.

Example

Sewing of some shapes into single shape.

Parameters:
    ListShape Shapes to be processed.
    theTolerance Required tolerance value.

Returns:
    New GEOM.GEOM_Object, containing processed shape.

Definition at line 4462 of file geompyDC.py.

04462 
04463         def MakeSewing(self, ListShape, theTolerance):
04464             """
04465             Sewing of some shapes into single shape.
04466 
04467             Parameters:
04468                 ListShape Shapes to be processed.
04469                 theTolerance Required tolerance value.
04470 
04471             Returns:
04472                 New GEOM.GEOM_Object, containing processed shape.
04473             """
04474             # Example: see GEOM_TestHealing.py
04475             comp = self.MakeCompound(ListShape)
04476             anObj = self.Sew(comp, theTolerance)
04477             return anObj

Here is the call graph for this function:

def geompyDC.geompyDC.OrientationChange (   self,
  theShape 
)

See ChangeOrientation() method for details.

Example

See geompy.ChangeOrientation method for details.

Definition at line 3136 of file geompyDC.py.

03136 
03137         def OrientationChange(self,theShape):
03138             """
03139             See geompy.ChangeOrientation method for details.
03140             """
03141             # Example: see GEOM_TestOthers.py
03142             anObj = self.ChangeOrientation(theShape)
03143             return anObj

Here is the call graph for this function:

def geompyDC.geompyDC.ProcessShape (   self,
  theShape,
  theOperators,
  theParameters,
  theValues 
)

Apply a sequence of Shape Healing operators to the given object.

Parameters:
theShapeShape to be processed.
theOperatorsList of names of operators ("FixShape", "SplitClosedFaces", etc.).
theParametersList of names of parameters ("FixShape.Tolerance3d", "SplitClosedFaces.NbSplitPoints", etc.).
theValuesList of values of parameters, in the same order as parameters are listed in theParameters list.

Operators and Parameters:

  • FixShape - corrects invalid shapes.
    • FixShape.Tolerance3d - work tolerance for detection of the problems and correction of them.
    • FixShape.MaxTolerance3d - maximal possible tolerance of the shape after correction.
  • FixFaceSize - removes small faces, such as spots and strips.
    • FixFaceSize.Tolerance - defines minimum possible face size.
    • DropSmallEdges - removes edges, which merge with neighbouring edges.
    • DropSmallEdges.Tolerance3d - defines minimum possible distance between two parallel edges.
  • SplitAngle - splits faces based on conical surfaces, surfaces of revolution and cylindrical surfaces in segments using a certain angle.
    • SplitAngle.Angle - the central angle of the resulting segments (i.e. we obtain two segments if Angle=180, four if Angle=90, etc).
    • SplitAngle.MaxTolerance - maximum possible tolerance among the resulting segments.
  • SplitClosedFaces - splits closed faces in segments. The number of segments depends on the number of splitting points.
    • SplitClosedFaces.NbSplitPoints - the number of splitting points.
  • SplitContinuity - splits shapes to reduce continuities of curves and surfaces.
    • SplitContinuity.Tolerance3d - 3D tolerance for correction of geometry.
    • SplitContinuity.SurfaceContinuity - required continuity for surfaces.
    • SplitContinuity.CurveContinuity - required continuity for curves.
      This and the previous parameters can take the following values:
      Parametric Continuity
      C0 (Positional Continuity): curves are joined (the end positions of curves or surfaces are coincidental. The curves or surfaces may still meet at an angle, giving rise to a sharp corner or edge).
      C1 (Tangential Continuity): first derivatives are equal (the end vectors of curves or surfaces are parallel, ruling out sharp edges).
      C2 (Curvature Continuity): first and second derivatives are equal (the end vectors of curves or surfaces are of the same magnitude).
      CN N-th derivatives are equal (both the direction and the magnitude of the Nth derivatives of curves or surfaces (d/du C(u)) are the same at junction.
      Geometric Continuity
      G1: first derivatives are proportional at junction.
      The curve tangents thus have the same direction, but not necessarily the same magnitude. i.e., C1'(1) = (a,b,c) and C2'(0) = (k*a, k*b, k*c).
      G2: first and second derivatives are proportional at junction. As the names imply, geometric continuity requires the geometry to be continuous, while parametric continuity requires that the underlying parameterization was continuous as well. Parametric continuity of order n implies geometric continuity of order n, but not vice-versa.
  • BsplineRestriction - converts curves and surfaces to Bsplines and processes them with the following parameters:
    • BSplineRestriction.SurfaceMode - approximation of surfaces if restriction is necessary.
    • BSplineRestriction.Curve3dMode - conversion of any 3D curve to BSpline and approximation.
    • BSplineRestriction.Curve2dMode - conversion of any 2D curve to BSpline and approximation.
    • BSplineRestriction.Tolerance3d - defines the possibility of surfaces and 3D curves approximation with the specified parameters.
    • BSplineRestriction.Tolerance2d - defines the possibility of surfaces and 2D curves approximation with the specified parameters.
    • BSplineRestriction.RequiredDegree - required degree of the resulting BSplines.
    • BSplineRestriction.RequiredNbSegments - required maximum number of segments of resultant BSplines.
    • BSplineRestriction.Continuity3d - continuity of the resulting surfaces and 3D curves.
    • BSplineRestriction.Continuity2d - continuity of the resulting 2D curves.
  • ToBezier - converts curves and surfaces of any type to Bezier curves and surfaces.
    • ToBezier.SurfaceMode - if checked in, allows conversion of surfaces.
    • ToBezier.Curve3dMode - if checked in, allows conversion of 3D curves.
    • ToBezier.Curve2dMode - if checked in, allows conversion of 2D curves.
    • ToBezier.MaxTolerance - defines tolerance for detection and correction of problems.
  • SameParameter - fixes edges of 2D and 3D curves not having the same parameter.
    • SameParameter.Tolerance3d - defines tolerance for fixing of edges.
Returns:
New GEOM.GEOM_Object, containing processed shape.


Example

Apply a sequence of Shape Healing operators to the given object.

Parameters:
    theShape Shape to be processed.
    theValues List of values of parameters, in the same order
  as parameters are listed in theParameters list.
    theOperators List of names of operators ("FixShape", "SplitClosedFaces", etc.).
    theParameters List of names of parameters
      ("FixShape.Tolerance3d", "SplitClosedFaces.NbSplitPoints", etc.).
     Operators and Parameters:

     * FixShape - corrects invalid shapes.
         * FixShape.Tolerance3d - work tolerance for detection of the problems and correction of them.
         * FixShape.MaxTolerance3d - maximal possible tolerance of the shape after correction.
     * FixFaceSize - removes small faces, such as spots and strips.
         * FixFaceSize.Tolerance - defines minimum possible face size.
         * DropSmallEdges - removes edges, which merge with neighbouring edges.
         * DropSmallEdges.Tolerance3d - defines minimum possible distance between two parallel edges.
     * SplitAngle - splits faces based on conical surfaces, surfaces of revolution and cylindrical surfaces
        in segments using a certain angle.
         * SplitAngle.Angle - the central angle of the resulting segments (i.e. we obtain two segments
                  if Angle=180, four if Angle=90, etc).
         * SplitAngle.MaxTolerance - maximum possible tolerance among the resulting segments.
     * SplitClosedFaces - splits closed faces in segments. The number of segments depends on the number of
              splitting points.
         * SplitClosedFaces.NbSplitPoints - the number of splitting points.
     * SplitContinuity - splits shapes to reduce continuities of curves and surfaces.
         * SplitContinuity.Tolerance3d - 3D tolerance for correction of geometry.
         * SplitContinuity.SurfaceContinuity - required continuity for surfaces.
         * SplitContinuity.CurveContinuity - required continuity for curves.
           This and the previous parameters can take the following values:
           
           Parametric Continuity:
           C0 (Positional Continuity): curves are joined (the end positions of curves or surfaces are
                           coincidental. The curves or surfaces may still meet at an angle,
                           giving rise to a sharp corner or edge).
           C1 (Tangential Continuity): first derivatives are equal (the end vectors of curves or surfaces
                           are parallel, ruling out sharp edges).
           C2 (Curvature Continuity): first and second derivatives are equal (the end vectors of curves
                          or surfaces are of the same magnitude).
           CN N-th derivatives are equal (both the direction and the magnitude of the Nth derivatives of
  curves or surfaces (d/du C(u)) are the same at junction.
  
           Geometric Continuity:
           G1: first derivatives are proportional at junction.
   The curve tangents thus have the same direction, but not necessarily the same magnitude.
   i.e., C1'(1) = (a,b,c) and C2'(0) = (k*a, k*b, k*c).
           G2: first and second derivatives are proportional at junction. As the names imply,
   geometric continuity requires the geometry to be continuous, while parametric continuity requires
   that the underlying parameterization was continuous as well. Parametric continuity of order n implies
   geometric continuity of order n, but not vice-versa.
     * BsplineRestriction - converts curves and surfaces to Bsplines and processes them with the following parameters:
         * BSplineRestriction.SurfaceMode - approximation of surfaces if restriction is necessary.
         * BSplineRestriction.Curve3dMode - conversion of any 3D curve to BSpline and approximation.
         * BSplineRestriction.Curve2dMode - conversion of any 2D curve to BSpline and approximation.
         * BSplineRestriction.Tolerance3d - defines the possibility of surfaces and 3D curves approximation with
                                the specified parameters.
         * BSplineRestriction.Tolerance2d - defines the possibility of surfaces and 2D curves approximation with
                                the specified parameters.
         * BSplineRestriction.RequiredDegree - required degree of the resulting BSplines.
         * BSplineRestriction.RequiredNbSegments - required maximum number of segments of resultant BSplines.
         * BSplineRestriction.Continuity3d - continuity of the resulting surfaces and 3D curves.
         * BSplineRestriction.Continuity2d - continuity of the resulting 2D curves.
     * ToBezier - converts curves and surfaces of any type to Bezier curves and surfaces.
         * ToBezier.SurfaceMode - if checked in, allows conversion of surfaces.
         * ToBezier.Curve3dMode - if checked in, allows conversion of 3D curves.
         * ToBezier.Curve2dMode - if checked in, allows conversion of 2D curves.
         * ToBezier.MaxTolerance - defines tolerance for detection and correction of problems.
     * SameParameter - fixes edges of 2D and 3D curves not having the same parameter.
         * SameParameter.Tolerance3d - defines tolerance for fixing of edges.

Returns:
    New GEOM.GEOM_Object, containing processed shape.

Note: For more information look through SALOME Geometry User's Guide->
      -> Introduction to Geometry-> Repairing Operations-> Shape Processing

Definition at line 4340 of file geompyDC.py.

04340 
04341         def ProcessShape(self, theShape, theOperators, theParameters, theValues):
04342             """
04343             Apply a sequence of Shape Healing operators to the given object.
04344 
04345             Parameters:
04346                 theShape Shape to be processed.
04347                 theValues List of values of parameters, in the same order
04348                           as parameters are listed in theParameters list.
04349                 theOperators List of names of operators ("FixShape", "SplitClosedFaces", etc.).
04350                 theParameters List of names of parameters
04351                               ("FixShape.Tolerance3d", "SplitClosedFaces.NbSplitPoints", etc.).
04352                  Operators and Parameters:
04353 
04354                  * FixShape - corrects invalid shapes.
04355                      * FixShape.Tolerance3d - work tolerance for detection of the problems and correction of them.
04356                      * FixShape.MaxTolerance3d - maximal possible tolerance of the shape after correction.
04357                  * FixFaceSize - removes small faces, such as spots and strips.
04358                      * FixFaceSize.Tolerance - defines minimum possible face size.
04359                      * DropSmallEdges - removes edges, which merge with neighbouring edges.
04360                      * DropSmallEdges.Tolerance3d - defines minimum possible distance between two parallel edges.
04361                  * SplitAngle - splits faces based on conical surfaces, surfaces of revolution and cylindrical surfaces
04362                                 in segments using a certain angle.
04363                      * SplitAngle.Angle - the central angle of the resulting segments (i.e. we obtain two segments
04364                                           if Angle=180, four if Angle=90, etc).
04365                      * SplitAngle.MaxTolerance - maximum possible tolerance among the resulting segments.
04366                  * SplitClosedFaces - splits closed faces in segments. The number of segments depends on the number of
04367                                       splitting points.
04368                      * SplitClosedFaces.NbSplitPoints - the number of splitting points.
04369                  * SplitContinuity - splits shapes to reduce continuities of curves and surfaces.
04370                      * SplitContinuity.Tolerance3d - 3D tolerance for correction of geometry.
04371                      * SplitContinuity.SurfaceContinuity - required continuity for surfaces.
04372                      * SplitContinuity.CurveContinuity - required continuity for curves.
04373                        This and the previous parameters can take the following values:
04374                        
04375                        Parametric Continuity:
04376                        C0 (Positional Continuity): curves are joined (the end positions of curves or surfaces are
04377                                                    coincidental. The curves or surfaces may still meet at an angle,
04378                                                    giving rise to a sharp corner or edge).
04379                        C1 (Tangential Continuity): first derivatives are equal (the end vectors of curves or surfaces
04380                                                    are parallel, ruling out sharp edges).
04381                        C2 (Curvature Continuity): first and second derivatives are equal (the end vectors of curves
04382                                                   or surfaces are of the same magnitude).
04383                        CN N-th derivatives are equal (both the direction and the magnitude of the Nth derivatives of
04384                           curves or surfaces (d/du C(u)) are the same at junction.
04385                           
04386                        Geometric Continuity:
04387                        G1: first derivatives are proportional at junction.
04388                            The curve tangents thus have the same direction, but not necessarily the same magnitude.
04389                            i.e., C1'(1) = (a,b,c) and C2'(0) = (k*a, k*b, k*c).
04390                        G2: first and second derivatives are proportional at junction. As the names imply,
04391                            geometric continuity requires the geometry to be continuous, while parametric continuity requires
04392                            that the underlying parameterization was continuous as well. Parametric continuity of order n implies
04393                            geometric continuity of order n, but not vice-versa.
04394                  * BsplineRestriction - converts curves and surfaces to Bsplines and processes them with the following parameters:
04395                      * BSplineRestriction.SurfaceMode - approximation of surfaces if restriction is necessary.
04396                      * BSplineRestriction.Curve3dMode - conversion of any 3D curve to BSpline and approximation.
04397                      * BSplineRestriction.Curve2dMode - conversion of any 2D curve to BSpline and approximation.
04398                      * BSplineRestriction.Tolerance3d - defines the possibility of surfaces and 3D curves approximation with
04399                                                         the specified parameters.
04400                      * BSplineRestriction.Tolerance2d - defines the possibility of surfaces and 2D curves approximation with
04401                                                         the specified parameters.
04402                      * BSplineRestriction.RequiredDegree - required degree of the resulting BSplines.
04403                      * BSplineRestriction.RequiredNbSegments - required maximum number of segments of resultant BSplines.
04404                      * BSplineRestriction.Continuity3d - continuity of the resulting surfaces and 3D curves.
04405                      * BSplineRestriction.Continuity2d - continuity of the resulting 2D curves.
04406                  * ToBezier - converts curves and surfaces of any type to Bezier curves and surfaces.
04407                      * ToBezier.SurfaceMode - if checked in, allows conversion of surfaces.
04408                      * ToBezier.Curve3dMode - if checked in, allows conversion of 3D curves.
04409                      * ToBezier.Curve2dMode - if checked in, allows conversion of 2D curves.
04410                      * ToBezier.MaxTolerance - defines tolerance for detection and correction of problems.
04411                  * SameParameter - fixes edges of 2D and 3D curves not having the same parameter.
04412                      * SameParameter.Tolerance3d - defines tolerance for fixing of edges.
04413 
04414             Returns:
04415                 New GEOM.GEOM_Object, containing processed shape.
04416 
04417             Note: For more information look through SALOME Geometry User's Guide->
04418                   -> Introduction to Geometry-> Repairing Operations-> Shape Processing
04419             """
04420             # Example: see GEOM_TestHealing.py
04421             theValues,Parameters = ParseList(theValues)
04422             anObj = self.HealOp.ProcessShape(theShape, theOperators, theParameters, theValues)
04423             # To avoid script failure in case of good argument shape
04424             if self.HealOp.GetErrorCode() == "ShHealOper_NotError_msg":
04425                 return theShape
04426             RaiseIfFailed("ProcessShape", self.HealOp)
04427             for string in (theOperators + theParameters):
04428                 Parameters = ":" + Parameters
04429                 pass
04430             anObj.SetParameters(Parameters)
04431             return anObj

Here is the call graph for this function:

def geompyDC.geompyDC.Sew (   self,
  theObject,
  theTolerance 
)

Sewing of the given object.

Parameters:
theObjectShape to be processed.
theToleranceRequired tolerance value.
Returns:
New GEOM.GEOM_Object, containing processed shape.
Sewing of the given object.

Parameters:
    theObject Shape to be processed.
    theTolerance Required tolerance value.

Returns:
    New GEOM.GEOM_Object, containing processed shape.

Definition at line 4482 of file geompyDC.py.

04482 
04483         def Sew(self, theObject, theTolerance):
04484             """
04485             Sewing of the given object.
04486 
04487             Parameters:
04488                 theObject Shape to be processed.
04489                 theTolerance Required tolerance value.
04490 
04491             Returns:
04492                 New GEOM.GEOM_Object, containing processed shape.
04493             """
04494             # Example: see MakeSewing() above
04495             theTolerance,Parameters = ParseParameters(theTolerance)
04496             anObj = self.HealOp.Sew(theObject, theTolerance)
04497             RaiseIfFailed("Sew", self.HealOp)
04498             anObj.SetParameters(Parameters)
04499             return anObj

Here is the call graph for this function:

Here is the caller graph for this function:

def geompyDC.geompyDC.SuppressFaces (   self,
  theObject,
  theFaces 
)

Remove faces from the given object (shape).

Parameters:
theObjectShape to be processed.
theFacesIndices of faces to be removed, if EMPTY then the method removes ALL faces of the given object.
Returns:
New GEOM.GEOM_Object, containing processed shape.

Example

Remove faces from the given object (shape).

Parameters:
    theObject Shape to be processed.
    theFaces Indices of faces to be removed, if EMPTY then the method
 removes ALL faces of the given object.

Returns:
    New GEOM.GEOM_Object, containing processed shape.

Definition at line 4439 of file geompyDC.py.

04439 
04440         def SuppressFaces(self,theObject, theFaces):
04441             """
04442             Remove faces from the given object (shape).
04443 
04444             Parameters:
04445                 theObject Shape to be processed.
04446                 theFaces Indices of faces to be removed, if EMPTY then the method
04447                          removes ALL faces of the given object.
04448 
04449             Returns:
04450                 New GEOM.GEOM_Object, containing processed shape.
04451             """
04452             # Example: see GEOM_TestHealing.py
04453             anObj = self.HealOp.SuppressFaces(theObject, theFaces)
04454             RaiseIfFailed("SuppressFaces", self.HealOp)
04455             return anObj

Here is the call graph for this function:

def geompyDC.geompyDC.SuppressHoles (   self,
  theObject,
  theWires 
)

Remove internal closed contours (holes) from the given object.

Parameters:
theObjectShape to be processed.
theWiresIndices of wires to be removed, if EMPTY then the method removes ALL internal holes of the given object
Returns:
New GEOM.GEOM_Object, containing processed shape.

Example

Remove internal closed contours (holes) from the given object.

Parameters:
    theObject Shape to be processed.
    theWires Indices of wires to be removed, if EMPTY then the method
 removes ALL internal holes of the given object

Returns:    
    New GEOM.GEOM_Object, containing processed shape.

Definition at line 4531 of file geompyDC.py.

04531 
04532         def SuppressHoles(self,theObject, theWires):
04533             """
04534             Remove internal closed contours (holes) from the given object.
04535 
04536             Parameters:
04537                 theObject Shape to be processed.
04538                 theWires Indices of wires to be removed, if EMPTY then the method
04539                          removes ALL internal holes of the given object
04540 
04541             Returns:    
04542                 New GEOM.GEOM_Object, containing processed shape.
04543             """
04544             # Example: see GEOM_TestHealing.py
04545             anObj = self.HealOp.FillHoles(theObject, theWires)
04546             RaiseIfFailed("FillHoles", self.HealOp)
04547             return anObj

Here is the call graph for this function:

def geompyDC.geompyDC.SuppressInternalWires (   self,
  theObject,
  theWires 
)

Remove internal wires and edges from the given object (face).

Parameters:
theObjectShape to be processed.
theWiresIndices of wires to be removed, if EMPTY then the method removes ALL internal wires of the given object.
Returns:
New GEOM.GEOM_Object, containing processed shape.

Example

Remove internal wires and edges from the given object (face).

Parameters:
    theObject Shape to be processed.
    theWires Indices of wires to be removed, if EMPTY then the method
 removes ALL internal wires of the given object.

Returns:                
    New GEOM.GEOM_Object, containing processed shape.

Definition at line 4507 of file geompyDC.py.

04507 
04508         def SuppressInternalWires(self,theObject, theWires):
04509             """
04510             Remove internal wires and edges from the given object (face).
04511 
04512             Parameters:
04513                 theObject Shape to be processed.
04514                 theWires Indices of wires to be removed, if EMPTY then the method
04515                          removes ALL internal wires of the given object.
04516 
04517             Returns:                
04518                 New GEOM.GEOM_Object, containing processed shape.
04519             """
04520             # Example: see GEOM_TestHealing.py
04521             anObj = self.HealOp.RemoveIntWires(theObject, theWires)
04522             RaiseIfFailed("RemoveIntWires", self.HealOp)
04523             return anObj

Here is the call graph for this function: