OCC.BRepAlgo module

class OCC.BRepAlgo.BRepAlgo_AsDes

Bases: OCC.MMgt.MMgt_TShared

Add()
  • Stores <SS> as a futur subshape of <S>.
Parameters:
  • S (TopoDS_Shape &) –
  • SS (TopoDS_Shape &) –
Return type:

None

  • Stores <SS> as futurs SubShapes of <S>.
Parameters:
  • S (TopoDS_Shape &) –
  • SS (TopTools_ListOfShape &) –
Return type:

None

Ascendant()
  • Returns the Shape containing <S>.
Parameters:S (TopoDS_Shape &) –
Return type:TopTools_ListOfShape
ChangeDescendant()
  • Returns futur subhapes of <S>.
Parameters:S (TopoDS_Shape &) –
Return type:TopTools_ListOfShape
Clear()
Return type:None
Descendant()
  • Returns futur subhapes of <S>.
Parameters:S (TopoDS_Shape &) –
Return type:TopTools_ListOfShape
GetHandle()

BRepAlgo_AsDes_GetHandle(BRepAlgo_AsDes self) -> Handle_BRepAlgo_AsDes

HasAscendant()
Parameters:S (TopoDS_Shape &) –
Return type:bool
HasCommonDescendant()
  • Returns True if (S1> and <S2> has common Descendants. Stores in <LC> the Commons Descendants.
Parameters:
  • S1 (TopoDS_Shape &) –
  • S2 (TopoDS_Shape &) –
  • LC (TopTools_ListOfShape &) –
Return type:

bool

HasDescendant()
Parameters:S (TopoDS_Shape &) –
Return type:bool
Remove()
  • Remove <S> from me.
Parameters:S (TopoDS_Shape &) –
Return type:None
Replace()
  • Replace <OldS> by <NewS>. <OldS> disapear from <self>.
Parameters:
  • OldS (TopoDS_Shape &) –
  • NewS (TopoDS_Shape &) –
Return type:

None

thisown

The membership flag

class OCC.BRepAlgo.BRepAlgo_BooleanOperation(*args, **kwargs)

Bases: OCC.BRepBuilderAPI.BRepBuilderAPI_MakeShape

Builder()
Return type:Handle_TopOpeBRepBuild_HBuilder
Perform()
Parameters:
  • St1 (TopAbs_State) –
  • St2 (TopAbs_State) –
Return type:

None

PerformDS()
Return type:None
Shape1()
  • Returns the first shape involved in this Boolean operation.
Return type:TopoDS_Shape
Shape2()
  • Returns the second shape involved in this Boolean operation.
Return type:TopoDS_Shape
thisown

The membership flag

class OCC.BRepAlgo.BRepAlgo_BooleanOperations

Bases: object

Builder()
Return type:Handle_TopOpeBRepBuild_HBuilder
ChangeBuilder()
Return type:Handle_TopOpeBRepBuild_HBuilder
ChangeDataStructure()
Return type:Handle_TopOpeBRepDS_HDataStructure
Common()
  • returns the common part of the shapes.
Return type:TopoDS_Shape
Cut()
  • returns the cut part of the shapes.
Return type:TopoDS_Shape
DataStructure()
Return type:Handle_TopOpeBRepDS_HDataStructure
DataStructureAccess()
  • returns the member myDSA. It is useful to then access the method GetSectionEdgeSet (wich is a member of DSAccess)
Return type:BRepAlgo_DSAccess
Define()
Parameters:
  • S1 (TopoDS_Shape &) –
  • S2 (TopoDS_Shape &) –
  • HDS (Handle_TopOpeBRepDS_HDataStructure &) –
Return type:

None

Fus()
  • returns the fuse part of the shapes.
Return type:TopoDS_Shape
IsDeleted()
  • Returns the fact that the shape <S> has been deleted or not by the boolean operation.
Parameters:S (TopoDS_Shape &) –
Return type:bool
Modified()
  • Returns the list of the descendant shapes of the shape <S>.
Parameters:S (TopoDS_Shape &) –
Return type:TopTools_ListOfShape
Section()
  • returns the intersection of the shapes.
Return type:TopoDS_Shape
SetApproxParameters()
  • Sets different parameters for the curve approximations : NbPntMax : Maximum number of points to be approximated at the same time in one curve. Tol3D, Tol2D : Tolerances to be reached by the approximation. RelativeTol : The given tolerances are relative.
Parameters:
  • NbPntMax (Standard_Integer) –
  • Tol3D (float) –
  • Tol2D (float) –
  • RelativeTol (bool) –
Return type:

None

Shape()
  • returns the result of the boolean operation.
Return type:TopoDS_Shape
ShapeFrom()
  • Returns the shape(s) resulting of the boolean operation issued from the shape <S>.
Parameters:S (TopoDS_Shape &) –
Return type:TopoDS_Shape
Shapes()
  • Defines the arguments.
Parameters:
  • S1 (TopoDS_Shape &) –
  • S2 (TopoDS_Shape &) –
Return type:

None

Shapes2d()
  • S1 is a Shell with ALL faces supported by the SAME S2 is an Edge INCLUDED in that surface with pcurve. this avoids a time-consuming 3D operation, compared to Shapes.
Parameters:
  • S1 (TopoDS_Shape &) –
  • S2 (TopoDS_Shape &) –
Return type:

None

thisown

The membership flag

class OCC.BRepAlgo.BRepAlgo_Common(*args)

Bases: OCC.BRepAlgo.BRepAlgo_BooleanOperation

thisown

The membership flag

class OCC.BRepAlgo.BRepAlgo_Cut(*args)

Bases: OCC.BRepAlgo.BRepAlgo_BooleanOperation

thisown

The membership flag

class OCC.BRepAlgo.BRepAlgo_DSAccess

Bases: object

Builder()
Return type:Handle_TopOpeBRepBuild_HBuilder
ChangeBuilder()
Return type:Handle_TopOpeBRepBuild_HBuilder
ChangeDS()
Return type:Handle_TopOpeBRepDS_HDataStructure
ChangeEdgeSet()
  • Modifies a line of section. <New> – should be a Group of Edges connected by Vertex. – Can be a Wire. Can be a group of connected Edges that do not form a standard Wire. <New> should be sub-groupn of <Old>
Parameters:
  • Old (TopoDS_Shape &) –
  • New (TopoDS_Shape &) –
Return type:

None

Check()
  • NYI coherence of the internal Data Structure.
Return type:BRepAlgo_CheckStatus
DS()
Return type:Handle_TopOpeBRepDS_HDataStructure
GetSectionEdgeSet()
  • returns compounds of Edge connected with section, which contains sections between faces contained in S1 and S2. returns an empty list of Shape if S1 or S2 do not contain face. calls GetSectionEdgeSet() if it has not already been done
Parameters:
  • S1 (TopoDS_Shape &) –
  • S2 (TopoDS_Shape &) –
Return type:

TopTools_ListOfShape

  • returns all compounds of edges connected with section contained in the DS
Return type:TopTools_ListOfShape
Init()
  • Clears the internal data structure, including the
Return type:None
Intersect()
  • Intersects two shapes at input and loads the DS with their intersection. Clears the TopOpeBRepBuild_HBuilder if necessary
Return type:None
  • Intersects the faces contained in two given shapes and loads them in the DS. Clears the TopOpeBRepBuild_HBuilder if necessary
Parameters:
  • S1 (TopoDS_Shape &) –
  • S2 (TopoDS_Shape &) –
Return type:

None

IsWire()
  • NYI
Parameters:Compound (TopoDS_Shape &) –
Return type:bool
Load()
  • Loads the shape in DS.
Parameters:S (TopoDS_Shape &) –
Return type:None
  • Loads two shapes in the DS without intersecting them.
Parameters:
  • S1 (TopoDS_Shape &) –
  • S2 (TopoDS_Shape &) –
Return type:

None

Merge()
Parameters:
  • state1 (TopAbs_State) –
  • state2 (TopAbs_State) –
  • state1
Return type:

TopoDS_Shape

Return type:

TopoDS_Shape

Modified()
  • Returns the list of the descendant shapes of the shape <S>.
Parameters:S (TopoDS_Shape &) –
Return type:TopTools_ListOfShape
Propagate()
  • NYI Propagation of a state starting from the shape FromShape = edge or vertex of section, face or Coumpound de section. LoadShape is either S1, or S2 (see the method Load). Propagation from FromShape, on the states <what> of LoadShape. Return a Wire in 2d, a Shell in 3d. Specifications are incomplete, to be redefined for the typologies correpsonding to <FromShape> and the result : exemple : FromShape resultat vertex wire (or edge) edge of section face (or shell) compound of section shell ... ...
Parameters:
  • what (TopAbs_State) –
  • FromShape (TopoDS_Shape &) –
  • LoadShape (TopoDS_Shape &) –
Return type:

TopoDS_Shape

PropagateFromSection()
  • SectionShape est soit un Vertex de section(NYI), soit une Edge de section. Propagation des shapes de section en partant de SectionShape. return un Compound de section.
Parameters:SectionShape (TopoDS_Shape &) –
Return type:TopoDS_Shape
SameDomain()
  • This method does the same thing as the previous, but faster. There is no intersection face/face 3D. The faces have the same support(surface). No test of tangency (that is why it is faster). Intersects in 2d the faces tangent F1 anf F2.
Parameters:
  • S1 (TopoDS_Shape &) –
  • S2 (TopoDS_Shape &) –
Return type:

None

SectionVertex()
  • NYI returns the vertex of section, which contains the section between face S1 and edge S2 (returns an empty Shape if S1 is not a face or if S2 is not an edge)
Parameters:
  • S1 (TopoDS_Shape &) –
  • S2 (TopoDS_Shape &) –
Return type:

TopTools_ListOfShape

SuppressEdgeSet()
  • Invalidates a complete line of section. All Edges connected by Vertex or a Wire. Can be a group of connected Edges, which do not form a standard Wire.
Parameters:Compound (TopoDS_Shape &) –
Return type:None
SuppressSectionVertex()
  • NYI Make invalid a Vertex of section. The Vertex shoud be reconstructed from a point.
Parameters:V (TopoDS_Vertex &) –
Return type:None
Wire()
  • NYI
Parameters:Compound (TopoDS_Shape &) –
Return type:TopoDS_Shape
thisown

The membership flag

class OCC.BRepAlgo.BRepAlgo_DataMapIteratorOfDataMapOfShapeBoolean(*args)

Bases: OCC.TCollection.TCollection_BasicMapIterator

Initialize()
Parameters:aMap (BRepAlgo_DataMapOfShapeBoolean &) –
Return type:None
Key()
Return type:TopoDS_Shape
Value()
Return type:bool
thisown

The membership flag

class OCC.BRepAlgo.BRepAlgo_DataMapIteratorOfDataMapOfShapeInterference(*args)

Bases: OCC.TCollection.TCollection_BasicMapIterator

Initialize()
Parameters:aMap (BRepAlgo_DataMapOfShapeInterference &) –
Return type:None
Key()
Return type:TopoDS_Shape
Value()
Return type:Handle_TopOpeBRepDS_Interference
thisown

The membership flag

class OCC.BRepAlgo.BRepAlgo_DataMapNodeOfDataMapOfShapeBoolean(*args)

Bases: OCC.TCollection.TCollection_MapNode

GetHandle()

BRepAlgo_DataMapNodeOfDataMapOfShapeBoolean_GetHandle(BRepAlgo_DataMapNodeOfDataMapOfShapeBoolean self) -> Handle_BRepAlgo_DataMapNodeOfDataMapOfShapeBoolean

GetValue()

BRepAlgo_DataMapNodeOfDataMapOfShapeBoolean_GetValue(BRepAlgo_DataMapNodeOfDataMapOfShapeBoolean self) -> Standard_Boolean

Key()
Return type:TopoDS_Shape
SetValue()

BRepAlgo_DataMapNodeOfDataMapOfShapeBoolean_SetValue(BRepAlgo_DataMapNodeOfDataMapOfShapeBoolean self, Standard_Boolean value)

thisown

The membership flag

class OCC.BRepAlgo.BRepAlgo_DataMapNodeOfDataMapOfShapeInterference(*args)

Bases: OCC.TCollection.TCollection_MapNode

GetHandle()

BRepAlgo_DataMapNodeOfDataMapOfShapeInterference_GetHandle(BRepAlgo_DataMapNodeOfDataMapOfShapeInterference self) -> Handle_BRepAlgo_DataMapNodeOfDataMapOfShapeInterference

Key()
Return type:TopoDS_Shape
Value()
Return type:Handle_TopOpeBRepDS_Interference
thisown

The membership flag

class OCC.BRepAlgo.BRepAlgo_DataMapOfShapeBoolean(NbBuckets=1)

Bases: OCC.TCollection.TCollection_BasicMap

Assign()
Parameters:Other (BRepAlgo_DataMapOfShapeBoolean &) –
Return type:BRepAlgo_DataMapOfShapeBoolean
Bind()
Parameters:
  • K (TopoDS_Shape &) –
  • I (bool) –
Return type:

bool

ChangeFind()
Parameters:K (TopoDS_Shape &) –
Return type:bool
ChangeFind1()
Parameters:K (TopoDS_Shape &) –
Return type:Standard_Address
Clear()
Return type:None
Find()
Parameters:K (TopoDS_Shape &) –
Return type:bool
Find1()
Parameters:K (TopoDS_Shape &) –
Return type:Standard_Address
IsBound()
Parameters:K (TopoDS_Shape &) –
Return type:bool
ReSize()
Parameters:NbBuckets (Standard_Integer) –
Return type:None
Set()
Parameters:Other (BRepAlgo_DataMapOfShapeBoolean &) –
Return type:BRepAlgo_DataMapOfShapeBoolean
UnBind()
Parameters:K (TopoDS_Shape &) –
Return type:bool
thisown

The membership flag

class OCC.BRepAlgo.BRepAlgo_DataMapOfShapeInterference(NbBuckets=1)

Bases: OCC.TCollection.TCollection_BasicMap

Assign()
Parameters:Other (BRepAlgo_DataMapOfShapeInterference &) –
Return type:BRepAlgo_DataMapOfShapeInterference
Bind()
Parameters:
  • K (TopoDS_Shape &) –
  • I (Handle_TopOpeBRepDS_Interference &) –
Return type:

bool

ChangeFind()
Parameters:K (TopoDS_Shape &) –
Return type:Handle_TopOpeBRepDS_Interference
ChangeFind1()
Parameters:K (TopoDS_Shape &) –
Return type:Standard_Address
Clear()
Return type:None
Find()
Parameters:K (TopoDS_Shape &) –
Return type:Handle_TopOpeBRepDS_Interference
Find1()
Parameters:K (TopoDS_Shape &) –
Return type:Standard_Address
IsBound()
Parameters:K (TopoDS_Shape &) –
Return type:bool
ReSize()
Parameters:NbBuckets (Standard_Integer) –
Return type:None
Set()
Parameters:Other (BRepAlgo_DataMapOfShapeInterference &) –
Return type:BRepAlgo_DataMapOfShapeInterference
UnBind()
Parameters:K (TopoDS_Shape &) –
Return type:bool
thisown

The membership flag

class OCC.BRepAlgo.BRepAlgo_EdgeConnector

Bases: OCC.MMgt.MMgt_TShared

Add()
Parameters:
  • e (TopoDS_Edge &) –
  • LOEdge (TopTools_ListOfShape &) –
Return type:

None

Return type:

None

AddStart()
Parameters:
  • e (TopoDS_Shape &) –
  • LOEdge (TopTools_ListOfShape &) –
Return type:

None

Return type:

None

ClearStartElement()
Return type:None
Done()
Return type:None
GetHandle()

BRepAlgo_EdgeConnector_GetHandle(BRepAlgo_EdgeConnector self) -> Handle_BRepAlgo_EdgeConnector

IsDone()
  • NYI returns true if proceeded to MakeBlock()
Return type:bool
IsWire()
  • NYI returns true if W is a Wire standard. W must belong to the list returned by MakeBlock.
Parameters:W (TopoDS_Shape &) –
Return type:bool
MakeBlock()
  • returns a list of wire non standard
Return type:TopTools_ListOfShape
thisown

The membership flag

class OCC.BRepAlgo.BRepAlgo_FaceRestrictor

Bases: object

Add()
  • Add the wire <W> to the set of wires. Warning: The Wires must be closed. The edges of <W> can be modified if they have not pcurves on the surface <S> of <F>. In this case if <Proj> is false the first pcurve of the edge is positionned on <S>. if <Proj> is True ,the Pcurve On <S> is the projection of the curve 3d on <F>.
Parameters:W (TopoDS_Wire &) –
Return type:None
Clear()
  • Removes all the Wires
Return type:None
Current()
Return type:TopoDS_Face
Init()
  • the surface of <F> will be the the surface of each new faces built. <Proj> is used to update pcurves on edges if necessary. See Add().
Parameters:
  • F (TopoDS_Face &) –
  • Proj (bool) – default value is Standard_False
  • ControlOrientation (bool) – default value is Standard_False
Return type:

None

  • the surface of <F> will be the the surface of each new faces built. <Proj> is used to update pcurves on edges if necessary. See Add().
Parameters:
  • F (TopoDS_Face &) –
  • Proj (bool) – default value is Standard_False
  • ControlOrientation (bool) – default value is Standard_False
Return type:

None

  • the surface of <F> will be the the surface of each new faces built. <Proj> is used to update pcurves on edges if necessary. See Add().
Parameters:
  • F (TopoDS_Face &) –
  • Proj (bool) – default value is Standard_False
  • ControlOrientation (bool) – default value is Standard_False
Return type:

None

IsDone()
Return type:bool
More()
Return type:bool
Next()
Return type:None
Perform()
  • Evaluate all the faces limited by the set of Wires.
Return type:None
thisown

The membership flag

class OCC.BRepAlgo.BRepAlgo_Fuse(*args)

Bases: OCC.BRepAlgo.BRepAlgo_BooleanOperation

thisown

The membership flag

class OCC.BRepAlgo.BRepAlgo_Image

Bases: object

Add()
  • Add <NewS> to the image of <OldS>.
Parameters:
  • OldS (TopoDS_Shape &) –
  • NewS (TopoDS_Shape &) –
Return type:

None

  • Add <NewS> to the image of <OldS>.
Parameters:
  • OldS (TopoDS_Shape &) –
  • NewS (TopTools_ListOfShape &) –
Return type:

None

Bind()
  • Links <NewS> as image of <OldS>.
Parameters:
  • OldS (TopoDS_Shape &) –
  • NewS (TopoDS_Shape &) –
Return type:

None

  • Links <NewS> as image of <OldS>.
Parameters:
  • OldS (TopoDS_Shape &) –
  • NewS (TopTools_ListOfShape &) –
Return type:

None

Clear()
Return type:None
Compact()
  • Keeps only the link between roots and lastimage.
Return type:None
Filter()
  • Deletes in the images the shape of type <ShapeType> which are not in <S>. Warning: Compact() must be call before.
Parameters:
  • S (TopoDS_Shape &) –
  • ShapeType (TopAbs_ShapeEnum) –
Return type:

None

HasImage()
Parameters:S (TopoDS_Shape &) –
Return type:bool
Image()
  • Returns the Image of <S>. Returns <S> in the list if HasImage(S) is false.
Parameters:S (TopoDS_Shape &) –
Return type:TopTools_ListOfShape
ImageFrom()
  • Returns the generator of <S>
Parameters:S (TopoDS_Shape &) –
Return type:TopoDS_Shape
IsImage()
Parameters:S (TopoDS_Shape &) –
Return type:bool
LastImage()
  • Stores in <L> the images of images of...images of <S>. <L> contains only <S> if HasImage(S) is false.
Parameters:
  • S (TopoDS_Shape &) –
  • L (TopTools_ListOfShape &) –
Return type:

None

Remove()
  • Remove <S> to set of images.
Parameters:S (TopoDS_Shape &) –
Return type:None
Root()
  • Returns the upper generator of <S>
Parameters:S (TopoDS_Shape &) –
Return type:TopoDS_Shape
Roots()
Return type:TopTools_ListOfShape
SetRoot()
Parameters:S (TopoDS_Shape &) –
Return type:None
thisown

The membership flag

class OCC.BRepAlgo.BRepAlgo_Loop

Bases: object

AddConstEdge()
  • Add <E> as const edge, E can be in the result.
Parameters:E (TopoDS_Edge &) –
Return type:None
AddConstEdges()
  • Add <LE> as a set of const edges.
Parameters:LE (TopTools_ListOfShape &) –
Return type:None
AddEdge()
  • Add E with <LV>. <E> will be copied and trim by vertices in <LV>.
Parameters:
  • E (TopoDS_Edge &) –
  • LV (TopTools_ListOfShape &) –
Return type:

None

CutEdge()
  • Cut the edge <E> in several edges <NE> on the vertices<VonE>.
Parameters:
  • E (TopoDS_Edge &) –
  • VonE (TopTools_ListOfShape &) –
  • NE (TopTools_ListOfShape &) –
Return type:

None

GetVerticesForSubstitute()
  • Returns the datamap of vertices with their substitutes.
Parameters:VerVerMap (TopTools_DataMapOfShapeShape &) –
Return type:None
Init()
  • Init with <F> the set of edges must have pcurves on <F>.
Parameters:F (TopoDS_Face &) –
Return type:None
NewEdges()
  • Returns the list of new edges built from an edge <E> it can be an empty list.
Parameters:E (TopoDS_Edge &) –
Return type:TopTools_ListOfShape
NewFaces()
  • Returns the list of faces. Warning: The method <WiresToFaces> as to be called before. can be an empty list.
Return type:TopTools_ListOfShape
NewWires()
  • Returns the list of wires performed. can be an empty list.
Return type:TopTools_ListOfShape
Perform()
  • Make loops.
Return type:None
VerticesForSubstitute()
Parameters:VerVerMap (TopTools_DataMapOfShapeShape &) –
Return type:None
WiresToFaces()
  • Build faces from the wires result.
Return type:None
thisown

The membership flag

class OCC.BRepAlgo.BRepAlgo_NormalProjection(*args)

Bases: object

Add()
  • Add an edge or a wire to the list of shape to project
Parameters:ToProj (TopoDS_Shape &) –
Return type:None
Ancestor()
  • For a resulting edge, returns the corresponding initial edge.
Parameters:E (TopoDS_Edge &) –
Return type:TopoDS_Shape
Build()
  • Builds the result as a compound.
Return type:None
BuildWire()
  • build the result as a list of wire if possible in – a first returns a wire only if there is only a wire.
Parameters:Liste (TopTools_ListOfShape &) –
Return type:bool
Compute3d()
  • if With3d = Standard_False the 3dcurve is not computed the initial 3dcurve is kept to build the resulting edges.
Parameters:With3d (bool) – default value is Standard_True
Return type:None
  • if With3d = Standard_False the 3dcurve is not computed the initial 3dcurve is kept to build the resulting edges.
Parameters:With3d (bool) – default value is Standard_True
Return type:None
Couple()
  • For a projected edge, returns the corresponding initial face.
Parameters:E (TopoDS_Edge &) –
Return type:TopoDS_Shape
Generated()
  • Returns the list of shapes generated from the shape <S>.
Parameters:S (TopoDS_Shape &) –
Return type:TopTools_ListOfShape
Init()
Parameters:S (TopoDS_Shape &) –
Return type:None
IsDone()
Return type:bool
IsElementary()
Parameters:C (Adaptor3d_Curve &) –
Return type:bool
Projection()
  • returns the result
Return type:TopoDS_Shape
SetDefaultParams()
  • Set the parameters used for computation in their default values
Return type:None
SetLimit()
  • Manage limitation of projected edges.
Parameters:FaceBoundaries (bool) – default value is Standard_True
Return type:None
  • Manage limitation of projected edges.
Parameters:FaceBoundaries (bool) – default value is Standard_True
Return type:None
SetMaxDistance()
  • Sets the maximum distance between target shape and shape to project. If this condition is not satisfied then corresponding part of solution is discarded. if MaxDist < 0 then this method does not affect the algorithm
Parameters:MaxDist (float) –
Return type:None
SetParams()
  • Set the parameters used for computation Tol3d is the requiered tolerance between the 3d projected curve and its 2d representation InternalContinuity is the order of constraints used for approximation. MaxDeg and MaxSeg are the maximum degree and the maximum number of segment for BSpline resulting of an approximation.
Parameters:
  • Tol3D (float) –
  • Tol2D (float) –
  • InternalContinuity (GeomAbs_Shape) –
  • MaxDegree (Standard_Integer) –
  • MaxSeg (Standard_Integer) –
Return type:

None

thisown

The membership flag

class OCC.BRepAlgo.BRepAlgo_Section(*args)

Bases: OCC.BRepAlgo.BRepAlgo_BooleanOperation

Approximation()
  • Defines an option for computation of further intersections. This computation will be performed by the function Build in this framework. By default, the underlying 3D geometry attached to each elementary edge of the result of a computed intersection is: - analytic where possible, provided the corresponding geometry corresponds to a type of analytic curve defined in the Geom package; for example the intersection of a cylindrical shape with a plane gives an ellipse or a circle; - or elsewhere, given as a succession of points grouped together in a BSpline curve of degree 1. If Approx equals true, when further computations are performed in this framework with the function Build, these edges will have an attached 3D geometry which is a BSpline approximation of the computed set of points. Note that as a result, approximations will be computed on edges built only on new intersection lines.
Parameters:B (bool) –
Return type:None
ComputePCurveOn1()
  • Indicates if the Pcurve must be (or not) performed on first part.
Parameters:B (bool) –
Return type:None
ComputePCurveOn2()
  • Define options for the computation of further intersections which will be performed by the function Build in this framework. By default, no parametric 2D curve (pcurve) is defined for the elementary edges of the result. If ComputePCurve1 equals true, further computations performed in this framework with the function Build will attach an additional pcurve in the parametric space of the first shape to the constructed edges. If ComputePCurve2 equals true, the additional pcurve will be attached to the constructed edges in the parametric space of the second shape. These two functions may be used together. Note that as a result, pcurves will only be added onto edges built on new intersection lines.
Parameters:B (bool) –
Return type:None
HasAncestorFaceOn1()
  • //!Identifies the ancestor faces of the new intersection edge E resulting from the last computation performed in this framework, that is, the faces of the two original shapes on which the edge E lies: - HasAncestorFaceOn1 gives the ancestor face in the first shape, and These functions return: - true if an ancestor face F is found, or - false if not. An ancestor face is identifiable for the edge E if the three following conditions are satisfied: - the first part on which this algorithm performed its last computation is a shape, that is, it was not given as a surface or a plane at the time of construction of this algorithm or at a later time by the Init1 function, - E is one of the elementary edges built by the last computation of this section algorithm, - the edge E is built on an intersection curve. In other words, E is a new edge built on the intersection curve, not on edges belonging to the intersecting shapes. To use these functions properly, you have to test the returned Boolean value before using the ancestor face: F is significant only if the returned Boolean value equals true.
Parameters:
  • E (TopoDS_Shape &) –
  • F (TopoDS_Shape &) –
Return type:

bool

HasAncestorFaceOn2()
  • Identifies the ancestor faces of the new intersection edge E resulting from the last computation performed in this framework, that is, the faces of the two original shapes on which the edge E lies: - HasAncestorFaceOn2 gives the ancestor face in the second shape. These functions return: - true if an ancestor face F is found, or - false if not. An ancestor face is identifiable for the edge E if the three following conditions are satisfied: - the first part on which this algorithm performed its last computation is a shape, that is, it was not given as a surface or a plane at the time of construction of this algorithm or at a later time by the Init1 function, - E is one of the elementary edges built by the last computation of this section algorithm, - the edge E is built on an intersection curve. In other words, E is a new edge built on the intersection curve, not on edges belonging to the intersecting shapes. To use these functions properly, you have to test the returned Boolean value before using the ancestor face: F is significant only if the returned Boolean value equals true.
Parameters:
  • E (TopoDS_Shape &) –
  • F (TopoDS_Shape &) –
Return type:

bool

Init1()
  • Initializes the first part
Parameters:S1 (TopoDS_Shape &) –
Return type:None
  • Initializes the first part
Parameters:Pl (gp_Pln) –
Return type:None
  • Initializes the first part
Parameters:Sf (Handle_Geom_Surface &) –
Return type:None
Init2()
  • initialize second part
Parameters:S2 (TopoDS_Shape &) –
Return type:None
  • Initializes the second part
Parameters:Pl (gp_Pln) –
Return type:None
  • This and the above algorithms reinitialize the first and the second parts on which this algorithm is going to perform the intersection computation. This is done with either: the surface Sf, the plane Pl or the shape Sh. You use the function Build to construct the result.
Parameters:Sf (Handle_Geom_Surface &) –
Return type:None
thisown

The membership flag

class OCC.BRepAlgo.BRepAlgo_SequenceNodeOfSequenceOfSequenceOfInteger(*args)

Bases: OCC.TCollection.TCollection_SeqNode

GetHandle()

BRepAlgo_SequenceNodeOfSequenceOfSequenceOfInteger_GetHandle(BRepAlgo_SequenceNodeOfSequenceOfSequenceOfInteger self) -> Handle_BRepAlgo_SequenceNodeOfSequenceOfSequenceOfInteger

Value()
Return type:TColStd_SequenceOfInteger
thisown

The membership flag

class OCC.BRepAlgo.BRepAlgo_SequenceOfSequenceOfInteger

Bases: OCC.TCollection.TCollection_BaseSequence

Append()
Parameters:
  • T (TColStd_SequenceOfInteger &) –
  • S (BRepAlgo_SequenceOfSequenceOfInteger &) –
Return type:

None

Return type:

None

Assign()
Parameters:Other (BRepAlgo_SequenceOfSequenceOfInteger &) –
Return type:BRepAlgo_SequenceOfSequenceOfInteger
ChangeValue()
Parameters:Index (Standard_Integer) –
Return type:TColStd_SequenceOfInteger
Clear()
Return type:None
First()
Return type:TColStd_SequenceOfInteger
InsertAfter()
Parameters:
  • Index (Standard_Integer) –
  • T (TColStd_SequenceOfInteger &) –
  • Index
  • S (BRepAlgo_SequenceOfSequenceOfInteger &) –
Return type:

None

Return type:

None

InsertBefore()
Parameters:
  • Index (Standard_Integer) –
  • T (TColStd_SequenceOfInteger &) –
  • Index
  • S (BRepAlgo_SequenceOfSequenceOfInteger &) –
Return type:

None

Return type:

None

Last()
Return type:TColStd_SequenceOfInteger
Prepend()
Parameters:
  • T (TColStd_SequenceOfInteger &) –
  • S (BRepAlgo_SequenceOfSequenceOfInteger &) –
Return type:

None

Return type:

None

Remove()
Parameters:
  • Index (Standard_Integer) –
  • FromIndex (Standard_Integer) –
  • ToIndex (Standard_Integer) –
Return type:

None

Return type:

None

Set()
Parameters:Other (BRepAlgo_SequenceOfSequenceOfInteger &) –
Return type:BRepAlgo_SequenceOfSequenceOfInteger
SetValue()
Parameters:
  • Index (Standard_Integer) –
  • I (TColStd_SequenceOfInteger &) –
Return type:

None

Split()
Parameters:
  • Index (Standard_Integer) –
  • Sub (BRepAlgo_SequenceOfSequenceOfInteger &) –
Return type:

None

Value()
Parameters:Index (Standard_Integer) –
Return type:TColStd_SequenceOfInteger
thisown

The membership flag

class OCC.BRepAlgo.BRepAlgo_Tool(*args, **kwargs)

Bases: object

static Deboucle3D(*args)
  • Remove the non valid part of an offsetshape 1 - Remove all the free boundary and the faces connex to such edges. 2 - Remove all the shapes not valid in the result (according to the side of offseting) in this verion only the first point is implemented.
Parameters:
  • S (TopoDS_Shape &) –
  • Boundary (TopTools_MapOfShape &) –
Return type:

TopoDS_Shape

thisown

The membership flag

OCC.BRepAlgo.BRepAlgo_Tool_Deboucle3D(*args)
  • Remove the non valid part of an offsetshape 1 - Remove all the free boundary and the faces connex to such edges. 2 - Remove all the shapes not valid in the result (according to the side of offseting) in this verion only the first point is implemented.
Parameters:
  • S (TopoDS_Shape &) –
  • Boundary (TopTools_MapOfShape &) –
Return type:

TopoDS_Shape

class OCC.BRepAlgo.Handle_BRepAlgo_AsDes(*args)

Bases: OCC.MMgt.Handle_MMgt_TShared

static DownCast()
GetObject()
IsNull()
Nullify()
thisown

The membership flag

class OCC.BRepAlgo.Handle_BRepAlgo_DataMapNodeOfDataMapOfShapeBoolean(*args)

Bases: OCC.TCollection.Handle_TCollection_MapNode

static DownCast()
GetObject()
IsNull()
Nullify()
thisown

The membership flag

class OCC.BRepAlgo.Handle_BRepAlgo_DataMapNodeOfDataMapOfShapeInterference(*args)

Bases: OCC.TCollection.Handle_TCollection_MapNode

static DownCast()
GetObject()
IsNull()
Nullify()
thisown

The membership flag

class OCC.BRepAlgo.Handle_BRepAlgo_EdgeConnector(*args)

Bases: OCC.MMgt.Handle_MMgt_TShared

static DownCast()
GetObject()
IsNull()
Nullify()
thisown

The membership flag

class OCC.BRepAlgo.Handle_BRepAlgo_SequenceNodeOfSequenceOfSequenceOfInteger(*args)

Bases: OCC.TCollection.Handle_TCollection_SeqNode

static DownCast()
GetObject()
IsNull()
Nullify()
thisown

The membership flag

class OCC.BRepAlgo.SwigPyIterator(*args, **kwargs)

Bases: object

advance()
copy()
decr()
distance()
equal()
incr()
next()
previous()
thisown

The membership flag

value()
class OCC.BRepAlgo.brepalgo(*args, **kwargs)

Bases: object

static ConcatenateWire(*args)
  • this method makes a wire whose edges are C1 from a Wire whose edges could be G1. It removes a vertex between G1 edges. Option can be G1 or C1.
Parameters:
  • Wire (TopoDS_Wire &) –
  • Option (GeomAbs_Shape) –
  • AngularTolerance (float) – default value is 1.0e-4
Return type:

TopoDS_Wire

  • this method makes a wire whose edges are C1 from a Wire whose edges could be G1. It removes a vertex between G1 edges. Option can be G1 or C1.
Parameters:
  • Wire (TopoDS_Wire &) –
  • Option (GeomAbs_Shape) –
  • AngularTolerance (float) – default value is 1.0e-4
Return type:

TopoDS_Wire

static ConcatenateWireC0(*args)
  • this method makes an edge from a wire. Junction points between edges of wire may be sharp, resulting curve of the resulting edge may be C0.
Parameters:Wire (TopoDS_Wire &) –
Return type:TopoDS_Edge
static IsTopologicallyValid(*args)
  • Checks if the shape is ‘correct’. If not, returns <Standard_False>, else returns <Standard_True>. This method differs from the previous one in the fact that no geometric contols (intersection of wires, pcurve validity) are performed.
Parameters:S (TopoDS_Shape &) –
Return type:bool
static IsValid(*args)
  • Checks if the shape is ‘correct’. If not, returns <Standard_False>, else returns <Standard_True>.
Parameters:S (TopoDS_Shape &) –
Return type:bool
  • Checks if the Generated and Modified Faces from the shapes <arguments> in the shape <result> are ‘correct’. The args may be empty, then all faces will be checked. If <Closed> is True, only closed shape are valid. If <GeomCtrl> is False the geometry of new vertices and edges are not verified and the auto-intersection of new wires are not searched.
Parameters:
  • theArgs (TopTools_ListOfShape &) –
  • theResult (TopoDS_Shape &) –
  • closedSolid (bool) – default value is Standard_False
  • GeomCtrl (bool) – default value is Standard_True
Return type:

bool

  • Checks if the Generated and Modified Faces from the shapes <arguments> in the shape <result> are ‘correct’. The args may be empty, then all faces will be checked. If <Closed> is True, only closed shape are valid. If <GeomCtrl> is False the geometry of new vertices and edges are not verified and the auto-intersection of new wires are not searched.
Parameters:
  • theArgs (TopTools_ListOfShape &) –
  • theResult (TopoDS_Shape &) –
  • closedSolid (bool) – default value is Standard_False
  • GeomCtrl (bool) – default value is Standard_True
Return type:

bool

  • Checks if the Generated and Modified Faces from the shapes <arguments> in the shape <result> are ‘correct’. The args may be empty, then all faces will be checked. If <Closed> is True, only closed shape are valid. If <GeomCtrl> is False the geometry of new vertices and edges are not verified and the auto-intersection of new wires are not searched.
Parameters:
  • theArgs (TopTools_ListOfShape &) –
  • theResult (TopoDS_Shape &) –
  • closedSolid (bool) – default value is Standard_False
  • GeomCtrl (bool) – default value is Standard_True
Return type:

bool

thisown

The membership flag

OCC.BRepAlgo.brepalgo_ConcatenateWire(*args)
  • this method makes a wire whose edges are C1 from a Wire whose edges could be G1. It removes a vertex between G1 edges. Option can be G1 or C1.
Parameters:
  • Wire (TopoDS_Wire &) –
  • Option (GeomAbs_Shape) –
  • AngularTolerance (float) – default value is 1.0e-4
Return type:

TopoDS_Wire

  • this method makes a wire whose edges are C1 from a Wire whose edges could be G1. It removes a vertex between G1 edges. Option can be G1 or C1.
Parameters:
  • Wire (TopoDS_Wire &) –
  • Option (GeomAbs_Shape) –
  • AngularTolerance (float) – default value is 1.0e-4
Return type:

TopoDS_Wire

OCC.BRepAlgo.brepalgo_ConcatenateWireC0(*args)
  • this method makes an edge from a wire. Junction points between edges of wire may be sharp, resulting curve of the resulting edge may be C0.
Parameters:Wire (TopoDS_Wire &) –
Return type:TopoDS_Edge
OCC.BRepAlgo.brepalgo_IsTopologicallyValid(*args)
  • Checks if the shape is ‘correct’. If not, returns <Standard_False>, else returns <Standard_True>. This method differs from the previous one in the fact that no geometric contols (intersection of wires, pcurve validity) are performed.
Parameters:S (TopoDS_Shape &) –
Return type:bool
OCC.BRepAlgo.brepalgo_IsValid(*args)
  • Checks if the shape is ‘correct’. If not, returns <Standard_False>, else returns <Standard_True>.
Parameters:S (TopoDS_Shape &) –
Return type:bool
  • Checks if the Generated and Modified Faces from the shapes <arguments> in the shape <result> are ‘correct’. The args may be empty, then all faces will be checked. If <Closed> is True, only closed shape are valid. If <GeomCtrl> is False the geometry of new vertices and edges are not verified and the auto-intersection of new wires are not searched.
Parameters:
  • theArgs (TopTools_ListOfShape &) –
  • theResult (TopoDS_Shape &) –
  • closedSolid (bool) – default value is Standard_False
  • GeomCtrl (bool) – default value is Standard_True
Return type:

bool

  • Checks if the Generated and Modified Faces from the shapes <arguments> in the shape <result> are ‘correct’. The args may be empty, then all faces will be checked. If <Closed> is True, only closed shape are valid. If <GeomCtrl> is False the geometry of new vertices and edges are not verified and the auto-intersection of new wires are not searched.
Parameters:
  • theArgs (TopTools_ListOfShape &) –
  • theResult (TopoDS_Shape &) –
  • closedSolid (bool) – default value is Standard_False
  • GeomCtrl (bool) – default value is Standard_True
Return type:

bool

  • Checks if the Generated and Modified Faces from the shapes <arguments> in the shape <result> are ‘correct’. The args may be empty, then all faces will be checked. If <Closed> is True, only closed shape are valid. If <GeomCtrl> is False the geometry of new vertices and edges are not verified and the auto-intersection of new wires are not searched.
Parameters:
  • theArgs (TopTools_ListOfShape &) –
  • theResult (TopoDS_Shape &) –
  • closedSolid (bool) – default value is Standard_False
  • GeomCtrl (bool) – default value is Standard_True
Return type:

bool