OCC.GCE2d module

class GCE2d_MakeArcOfCircle(*args)

Bases: OCC.GCE2d.GCE2d_Root

  • Makes an arc of circle (TrimmedCurve from Geom2d) from a circle between two parameters Alpha1 and Alpha2. The two parameters are angles. The parameters are in radians.
Parameters:
Return type:

None

  • Makes an arc of circle (TrimmedCurve from Geom2d) from a circle between point <P> and the parameter Alpha. Alpha is given in radians.
Parameters:
Return type:

None

  • Makes an arc of circle (TrimmedCurve from Geom2d) from a circle between two points P1 and P2.
Parameters:
Return type:

None

  • Makes an arc of circle (TrimmedCurve from Geom2d) from three points P1,P2,P3 between two points P1 and P3, and passing through the point P2.
Parameters:
Return type:

None

  • Makes an arc of circle (TrimmedCurve from Geom2d) from two points P1,P2 and the tangente to the solution at the point P1.
Parameters:
Return type:

None

Operator()
Return type:Handle_Geom2d_TrimmedCurve
Value()
  • Returns the constructed arc of circle. Exceptions StdFail_NotDone if no arc of circle is constructed.
Return type:Handle_Geom2d_TrimmedCurve
thisown

The membership flag

class GCE2d_MakeArcOfEllipse(*args)

Bases: OCC.GCE2d.GCE2d_Root

  • Make an arc of Ellipse (TrimmedCurve from Geom2d) from a Ellipse between two parameters Alpha1 and Alpha2.
Parameters:
Return type:

None

  • Make an arc of Ellipse (TrimmedCurve from Geom2d) from a Ellipse between point <P> and the parameter Alpha.
Parameters:
Return type:

None

  • Make an arc of Ellipse (TrimmedCurve from Geom2d) from a Ellipse between two points P1 and P2. Please, note: The orientation of the arc is: - the trigonometric sense if Sense is not defined or is true (default value), or - the opposite sense if Sense is false. - Alpha1, Alpha2 and Alpha are angle values, given in radians. - IsDone always returns true.
Parameters:
Return type:

None

Operator()
Return type:Handle_Geom2d_TrimmedCurve
Value()
  • Returns the constructed arc of ellipse.
Return type:Handle_Geom2d_TrimmedCurve
thisown

The membership flag

class GCE2d_MakeArcOfHyperbola(*args)

Bases: OCC.GCE2d.GCE2d_Root

  • Makes an arc of Hyperbola (TrimmedCurve from Geom2d) from a Hyperbola between two parameters Alpha1 and Alpha2.
Parameters:
Return type:

None

  • Makes an arc of Hyperbola (TrimmedCurve from Geom2d) from a Hyperbola between point <P> and the parameter Alpha.
Parameters:
Return type:

None

  • Makes an arc of Hyperbola (TrimmedCurve from Geom2d) from a Hyperbola between two points P1 and P2. Note: the orientation of the arc of hyperbola is: - the trigonometric sense if Sense is not defined or is true (default value), or - the opposite sense if Sense is false. - IsDone always returns true.
Parameters:
Return type:

None

Operator()
Return type:Handle_Geom2d_TrimmedCurve
Value()
  • Returns the constructed arc of hyperbola.
Return type:Handle_Geom2d_TrimmedCurve
thisown

The membership flag

class GCE2d_MakeArcOfParabola(*args)

Bases: OCC.GCE2d.GCE2d_Root

  • Make an arc of Parabola (TrimmedCurve from Geom2d) from a Parabola between two parameters Alpha1 and Alpha2.
Parameters:
Return type:

None

  • Make an arc of Parabola (TrimmedCurve from Geom2d) from a Parabola between point <P> and the parameter Alpha.
Parameters:
Return type:

None

  • Make an arc of Parabola (TrimmedCurve from Geom2d) from a Parabola between two points P1 and P2. Please, note: the orientation of the arc of parabola is: - the trigonometric sense if Sense is not defined or is true (default value), or - the opposite sense if Sense is false. - IsDone always returns true.
Parameters:
Return type:

None

Operator()
Return type:Handle_Geom2d_TrimmedCurve
Value()
  • Returns the constructed arc of parabola.
Return type:Handle_Geom2d_TrimmedCurve
thisown

The membership flag

class GCE2d_MakeCircle(*args)

Bases: OCC.GCE2d.GCE2d_Root

  • creates a circle from a non persistent one.
Parameters:C (gp_Circ2d) –
Return type:None
  • A is the ‘XAxis’ of the circle which defines the origin of parametrization. It is not forbidden to create a circle with Radius = 0.0 The status is ‘NegativeRadius’ if Radius < 0.
Parameters:
  • A (gp_Ax2d) –
  • Radius (float) –
  • Sense (bool) – default value is Standard_True
Return type:

None

  • A is the local coordinate system of the circle which defines the origin of parametrization. It is not forbidden to create a circle with Radius = 0.0 The status is ‘NegativeRadius’ if Radius < 0.
Parameters:
Return type:

None

  • Make a Circle from Geom2d <TheCirc> parallel to another Circ <Circ> with a distance <Dist>. If Dist is greater than zero the result is enclosing the circle <Circ>, else the result is enclosed by the circle <Circ>.
Parameters:
Return type:

None

  • Make a Circle from Geom2d <TheCirc> parallel to another Circ <Circ> and passing through a Pnt <Point>.
Parameters:
Return type:

None

  • Make a Circ from gp <TheCirc> passing through 3 Pnt2d <P1>,<P2>,<P3>.
Parameters:
Return type:

None

  • Make a Circ from geom2d <TheCirc> by its center an radius.
Parameters:
  • P (gp_Pnt2d) –
  • Radius (float) –
  • Sense (bool) – default value is Standard_True
Return type:

None

  • Makes a Circle from geom2d <TheCirc> with its center <Center> and a point giving the radius. If Sense is true the local coordinate system of the solution is direct and non direct in the other case. Warning The MakeCircle class does not prevent the construction of a circle with a null radius. If an error occurs (that is, when IsDone returns false), the Status function returns: - gce_NegativeRadius if Radius is less than 0.0, or - gce_IntersectionError if points P1, P2 and P3 are collinear and the three are not coincident.
Parameters:
Return type:

None

Operator()
Return type:Handle_Geom2d_Circle
Value()
  • Returns the constructed circle. Exceptions StdFail_NotDone if no circle is constructed.
Return type:Handle_Geom2d_Circle
thisown

The membership flag

class GCE2d_MakeEllipse(*args)

Bases: OCC.GCE2d.GCE2d_Root

  • Creates an ellipse from a non persistent one from package gp
Parameters:E (gp_Elips2d) –
Return type:None
  • MajorAxis is the local coordinate system of the ellipse. It is the ‘XAxis’. The minor axis is the YAxis of the ellipse. Sense give the sense of parametrization of the Ellipse. It is not forbidden to create an ellipse with MajorRadius = MinorRadius. The status is ‘InvertRadius’ if MajorRadius < MinorRadius or ‘NegativeRadius’ if MinorRadius < 0.
Parameters:
  • MajorAxis (gp_Ax2d) –
  • MajorRadius (float) –
  • MinorRadius (float) –
  • Sense (bool) – default value is Standard_True
Return type:

None

  • Axis is the local coordinate system of the ellipse. It is not forbidden to create an ellipse with MajorRadius = MinorRadius. The status is ‘InvertRadius’ if MajorRadius < MinorRadius or ‘NegativeRadius’ if MinorRadius < 0.
Parameters:
Return type:

None

  • Make an Ellipse centered on the point Center, where - the major axis of the ellipse is defined by Center and S1, - its major radius is the distance between Center and S1, and - its minor radius is the distance between S2 and the major axis. The implicit orientation of the ellipse is: - the sense defined by Axis or E, - the sense defined by points Center, S1 and S2, - the trigonometric sense if Sense is not given or is true, or - the opposite sense if Sense is false.
Parameters:
Return type:

None

Operator()
Return type:Handle_Geom2d_Ellipse
Value()
  • Returns the constructed ellipse. Exceptions StdFail_NotDone if no ellipse is constructed.
Return type:Handle_Geom2d_Ellipse
thisown

The membership flag

class GCE2d_MakeHyperbola(*args)

Bases: OCC.GCE2d.GCE2d_Root

  • Creates an Hyperbola from a non persistent one from package gp
Parameters:H (gp_Hypr2d) –
Return type:None
  • MajorAxis is the ‘XAxis’ of the hyperbola. The major radius of the hyperbola is on this ‘XAxis’ and the minor radius is on the ‘YAxis’ of the hyperbola. The status is ‘NegativeRadius’ if MajorRadius < 0.0 or if MinorRadius < 0.0
Parameters:
Return type:

None

  • Axis is the local coordinate system of the hyperbola. The major radius of the hyperbola is on this ‘XAxis’ and the minor radius is on the ‘YAxis’ of the hyperbola. The status is ‘NegativeRadius’ if MajorRadius < 0.0 or if MinorRadius < 0.0
Parameters:
Return type:

None

  • Creates a hyperbol centered on the origin of the coordinate system Axis, with major and minor radii MajorRadius and MinorRadius, where the major axis is the ‘X Axis’ of Axis (Axis is the local coordinate system of the hyperbola). The implicit orientation of the ellipse is: - the sense defined by Axis or H, - the sense defined by points Center, S1 and S2, - the trigonometric sense if Sense is not given or is true, or - the opposite sense if Sense is false. Warning If an error occurs (that is, when IsDone returns false), the Status function returns: - gce_NegativeRadius if MajorRadius or MinorRadius is less than 0.0, or - gce_InvertAxis if the major radius defined by Center and S1 is less than the minor radius defined by Center, S1 and S2.Make an Hyperbola with its center and two apexes.
Parameters:
Return type:

None

Operator()
Return type:Handle_Geom2d_Hyperbola
Value()
  • Returns the constructed hyperbola. Exceptions: StdFail_NotDone if no hyperbola is constructed.
Return type:Handle_Geom2d_Hyperbola
thisown

The membership flag

class GCE2d_MakeLine(*args)

Bases: OCC.GCE2d.GCE2d_Root

  • Creates a line located in 2D space with the axis placement A. The Location of A is the origin of the line.
Parameters:A (gp_Ax2d) –
Return type:None
  • Creates a line from a non persistent line from package gp.
Parameters:L (gp_Lin2d) –
Return type:None
  • P is the origin and V is the direction of the line.
Parameters:
Return type:

None

  • Make a Line from Geom2d <TheLin> parallel to another Lin <Lin> and passing through a Pnt <Point>.
Parameters:
Return type:

None

  • Make a Line from Geom2d <TheLin> parallel to another Lin <Lin> at a distance <Dist>.
Parameters:
Return type:

None

  • Make a Line from Geom2d <TheLin> passing through 2 Pnt <P1>,<P2>. It returns false if <p1> and <P2> are confused. Warning If points P1 and P2 coincident (that is, when IsDone returns false), the Status function returns gce_ConfusedPoints.
Parameters:
Return type:

None

Operator()
Return type:Handle_Geom2d_Line
Value()
  • Returns the constructed line. Exceptions StdFail_NotDone if no line is constructed.
Return type:Handle_Geom2d_Line
thisown

The membership flag

class GCE2d_MakeMirror(*args)

Bases: object

Parameters:
Return type:

None

Return type:

None

Return type:

None

  • Make a symetry transformation af axis defined by <Point> and <Direc>.
Parameters:
Return type:

None

Operator()
Return type:Handle_Geom2d_Transformation
Value()
  • Returns the constructed transformation.
Return type:Handle_Geom2d_Transformation
thisown

The membership flag

class GCE2d_MakeParabola(*args)

Bases: OCC.GCE2d.GCE2d_Root

  • Creates a parabola from a non persistent one.
Parameters:Prb (gp_Parab2d) –
Return type:None
  • Creates a parabola with its local coordinate system and it’s focal length ‘Focal’. The ‘Location’ point of ‘Axis’ is the vertex of the parabola Status is ‘NegativeFocusLength’ if Focal < 0.0
Parameters:
Return type:

None

  • Creates a parabola with its ‘MirrorAxis’ and it’s focal length ‘Focal’. MirrorAxis is the axis of symmetry of the curve, it is the ‘XAxis’. The ‘YAxis’ is parallel to the directrix of the parabola. The ‘Location’ point of ‘MirrorAxis’ is the vertex of the parabola Status is ‘NegativeFocusLength’ if Focal < 0.0
Parameters:
Return type:

None

  • Creates a parabola with the local coordinate system and the focus point. The sense of parametrization is given by Sense.
Parameters:
Return type:

None

  • D is the directrix of the parabola and F the focus point. The symmetry axis ‘XAxis’ of the parabola is normal to the directrix and pass through the focus point F, but its ‘Location’ point is the vertex of the parabola. The ‘YAxis’ of the parabola is parallel to D and its ‘Location’ point is the vertex of the parabola.
Parameters:
Return type:

None

  • Make a parabola with focal point S1 and center O The branch of the parabola returned will have <S1> as focal point The implicit orientation of the parabola is: - the same one as the parabola Prb, - the sense defined by the coordinate system Axis or the directrix D, - the trigonometric sense if Sense is not given or is true, or - the opposite sense if Sense is false. Warning The MakeParabola class does not prevent the construction of a parabola with a null focal distance. If an error occurs (that is, when IsDone returns false), the Status function returns: - gce_NullFocusLength if Focal is less than 0.0, or - gce_NullAxis if points S1 and O are coincident.
Parameters:
Return type:

None

Operator()
Return type:Handle_Geom2d_Parabola
Value()
  • Returns the constructed parabola. Exceptions StdFail_NotDone if no parabola is constructed.
Return type:Handle_Geom2d_Parabola
thisown

The membership flag

class GCE2d_MakeRotation(*args)

Bases: object

  • Constructs a rotation through angle Angle about the center Point.
Parameters:
Return type:

None

Operator()
Return type:Handle_Geom2d_Transformation
Value()
  • Returns the constructed transformation.
Return type:Handle_Geom2d_Transformation
thisown

The membership flag

class GCE2d_MakeScale(*args)

Bases: object

  • Constructs a scaling transformation with - Point as the center of the transformation, and - Scale as the scale factor.
Parameters:
Return type:

None

Operator()
Return type:Handle_Geom2d_Transformation
Value()
  • Returns the constructed transformation.
Return type:Handle_Geom2d_Transformation
thisown

The membership flag

class GCE2d_MakeSegment(*args)

Bases: OCC.GCE2d.GCE2d_Root

  • Make a segment of Line from the 2 points <P1> and <P2>. Status is ‘ConfusedPoints’ if <P1> and <P2> are confused.
Parameters:
Return type:

None

  • Make a segment of Line from the point <P1> with the direction <P> and ended by the projection of <P2> on the line <P1,V>. Status is ‘ConfusedPoints’ if <P1> and <P2> are confused.
Parameters:
Return type:

None

  • Make a segment of Line from the line <Line> between the two parameters U1 and U2. Status is ‘SameParamters’ if <U1> is equal <U2>.
Parameters:
Return type:

None

  • Make a segment of Line from the line <Line> between the point <Point> and the parameter Ulast. It returns NullObject if <U1> is equal <U2>.
Parameters:
Return type:

None

  • Make a segment of Line from the line <Line> between the two points <P1> and <P2>. It returns NullObject if <P1> and <P2> are confused. Warning If the points which limit the segment are coincident for given points or for the projection of given points on the line which supports the line segment (that is, when IsDone returns false), the Status function returns gce_ConfusedPoints. This warning only concerns the first two constructors.
Parameters:
Return type:

None

Operator()
Return type:Handle_Geom2d_TrimmedCurve
Value()
  • Returns the constructed line segment. Exceptions StdFail_NotDone if no line segment is constructed.
Return type:Handle_Geom2d_TrimmedCurve
thisown

The membership flag

class GCE2d_MakeTranslation(*args)

Bases: object

  • Constructs a translation along the vector Vect.
Parameters:Vect (gp_Vec2d) –
Return type:None
  • Constructs a translation along the vector (Point1,Point2) defined from the point Point1 to the point Point2.
Parameters:
Return type:

None

Operator()
Return type:Handle_Geom2d_Transformation
Value()
  • Returns the constructed transformation.
Return type:Handle_Geom2d_Transformation
thisown

The membership flag

class GCE2d_Root

Bases: object

IsDone()
  • Returns true if the construction is successful.
Return type:bool
Status()
  • Returns the status of the construction - gce_Done, if the construction is successful, or - another value of the gce_ErrorType enumeration indicating why the construction failed.
Return type:gce_ErrorType
thisown

The membership flag

class SwigPyIterator(*args, **kwargs)

Bases: object

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

The membership flag

value()
new_instancemethod(func, inst, cls)
register_handle(handle, base_object)

Inserts the handle into the base object to prevent memory corruption in certain cases