Open CASCADE Technology Reference Manual 8.0.0
Loading...
Searching...
No Matches
Public Member Functions
GC_MakeSegment2d Class Reference

This class implements construction algorithms for line segments in the plane. The result is a Geom2d_TrimmedCurve. A GC_MakeSegment2d object provides a framework for: More...

#include <GC_MakeSegment2d.hxx>

Inheritance diagram for GC_MakeSegment2d:
Inheritance graph
[legend]

Public Member Functions

 GC_MakeSegment2d (const gp_Pnt2d &theP1, const gp_Pnt2d &theP2)
 Creates a segment between two points.
 
 GC_MakeSegment2d (const gp_Pnt2d &theP1, const gp_Dir2d &theV, const gp_Pnt2d &theP2)
 Creates a segment on a line defined by point and direction. The segment starts at theP1 and ends at the orthogonal projection of theP2 onto that line.
 
 GC_MakeSegment2d (const gp_Lin2d &theLine, const double theU1, const double theU2)
 Creates a segment on a line between two parameter values.
 
 GC_MakeSegment2d (const gp_Lin2d &theLine, const gp_Pnt2d &thePoint, const double theUlast)
 Creates a segment on a line between point parameter and target parameter.
 
 GC_MakeSegment2d (const gp_Lin2d &theLine, const gp_Pnt2d &theP1, const gp_Pnt2d &theP2)
 Creates a segment on a line between projections of two points.
 
const occ::handle< Geom2d_TrimmedCurve > & Value () const
 Returns the constructed line segment. Exceptions StdFail_NotDone if no line segment is constructed.
 
 operator const occ::handle< Geom2d_TrimmedCurve > & () const
 Conversion operator returning the constructed object.
 
- Public Member Functions inherited from GC_Root
bool IsDone () const
 Returns true if the construction is successful.
 
bool IsError () const
 Returns true if the construction has failed.
 
gce_ErrorType Status () const
 Returns the status of the construction:
 

Additional Inherited Members

- Protected Attributes inherited from GC_Root
gce_ErrorType TheError
 

Detailed Description

This class implements construction algorithms for line segments in the plane. The result is a Geom2d_TrimmedCurve. A GC_MakeSegment2d object provides a framework for:

Constructor & Destructor Documentation

◆ GC_MakeSegment2d() [1/5]

GC_MakeSegment2d::GC_MakeSegment2d ( const gp_Pnt2d & theP1,
const gp_Pnt2d & theP2 )

Creates a segment between two points.

Parameters
[in]theP1first point
[in]theP2second point
Note
Construction fails with gce_ConfusedPoints if points are coincident.

◆ GC_MakeSegment2d() [2/5]

GC_MakeSegment2d::GC_MakeSegment2d ( const gp_Pnt2d & theP1,
const gp_Dir2d & theV,
const gp_Pnt2d & theP2 )

Creates a segment on a line defined by point and direction. The segment starts at theP1 and ends at the orthogonal projection of theP2 onto that line.

Parameters
[in]theP1first point
[in]theVdirection vector
[in]theP2second point
Note
Construction fails with gce_ConfusedPoints if the projected endpoint is coincident with theP1 within resolution.

◆ GC_MakeSegment2d() [3/5]

GC_MakeSegment2d::GC_MakeSegment2d ( const gp_Lin2d & theLine,
const double theU1,
const double theU2 )

Creates a segment on a line between two parameter values.

Parameters
[in]theLinesource line
[in]theU1first parameter
[in]theU2second parameter

◆ GC_MakeSegment2d() [4/5]

GC_MakeSegment2d::GC_MakeSegment2d ( const gp_Lin2d & theLine,
const gp_Pnt2d & thePoint,
const double theUlast )

Creates a segment on a line between point parameter and target parameter.

Parameters
[in]theLinesource line
[in]thePointfirst point on segment support line
[in]theUlastlast parameter

◆ GC_MakeSegment2d() [5/5]

GC_MakeSegment2d::GC_MakeSegment2d ( const gp_Lin2d & theLine,
const gp_Pnt2d & theP1,
const gp_Pnt2d & theP2 )

Creates a segment on a line between projections of two points.

Parameters
[in]theLinesource line
[in]theP1first point
[in]theP2second point

Member Function Documentation

◆ operator const occ::handle< Geom2d_TrimmedCurve > &()

GC_MakeSegment2d::operator const occ::handle< Geom2d_TrimmedCurve > & ( ) const
inline

Conversion operator returning the constructed object.

Returns
resulting trimmed curve

◆ Value()

const occ::handle< Geom2d_TrimmedCurve > & GC_MakeSegment2d::Value ( ) const

Returns the constructed line segment. Exceptions StdFail_NotDone if no line segment is constructed.

Returns
resulting trimmed curve

The documentation for this class was generated from the following file: