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

This class implements construction algorithms for gp_Dir2d. Supported constructions include: More...

#include <gce_MakeDir2d.hxx>

Inheritance diagram for gce_MakeDir2d:
Inheritance graph
[legend]

Public Member Functions

 gce_MakeDir2d (const gp_Vec2d &V)
 Normalizes the vector V and creates a direction.
 
 gce_MakeDir2d (const gp_XY &Coord)
 Creates a direction from a coordinate vector.
 
 gce_MakeDir2d (const double Xv, const double Yv)
 Creates a direction with its two cartesian coordinates.
 
 gce_MakeDir2d (const gp_Pnt2d &P1, const gp_Pnt2d &P2)
 Creates a direction from two points.
 
const gp_Dir2dValue () const
 Returns the constructed unit vector. Exceptions StdFail_NotDone if no unit vector is constructed.
 
gp_Dir2d Operator () const
 Alias for Value() returning a copy.
 
 operator gp_Dir2d () const
 Conversion operator returning the constructed object.
 
- Public Member Functions inherited from gce_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 gce_Root
gce_ErrorType TheError
 

Detailed Description

This class implements construction algorithms for gp_Dir2d. Supported constructions include:

Constructor & Destructor Documentation

◆ gce_MakeDir2d() [1/4]

gce_MakeDir2d::gce_MakeDir2d ( const gp_Vec2d & V)

Normalizes the vector V and creates a direction.

Note
Construction fails with gce_NullVector if V.Magnitude() <= gp::Resolution().
Parameters
[in]Vdirection vector

◆ gce_MakeDir2d() [2/4]

gce_MakeDir2d::gce_MakeDir2d ( const gp_XY & Coord)

Creates a direction from a coordinate vector.

Note
Construction fails with gce_NullVector if Coord.Modulus() <= gp::Resolution().
Parameters
[in]Coordcoordinate vector

◆ gce_MakeDir2d() [3/4]

gce_MakeDir2d::gce_MakeDir2d ( const double Xv,
const double Yv )

Creates a direction with its two cartesian coordinates.

Note
Construction fails with gce_NullVector if Xv*Xv + Yv*Yv <= gp::Resolution().
Parameters
[in]XvX coordinate value
[in]YvY coordinate value

◆ gce_MakeDir2d() [4/4]

gce_MakeDir2d::gce_MakeDir2d ( const gp_Pnt2d & P1,
const gp_Pnt2d & P2 )

Creates a direction from two points.

Note
Construction fails with gce_ConfusedPoints if points are coincident.
Parameters
[in]P1first point
[in]P2second point

Member Function Documentation

◆ Operator()

gp_Dir2d gce_MakeDir2d::Operator ( ) const
inline

Alias for Value() returning a copy.

Returns
resulting object

◆ operator gp_Dir2d()

gce_MakeDir2d::operator gp_Dir2d ( ) const
inline

Conversion operator returning the constructed object.

Returns
resulting object

◆ Value()

const gp_Dir2d & gce_MakeDir2d::Value ( ) const

Returns the constructed unit vector. Exceptions StdFail_NotDone if no unit vector is constructed.

Returns
resulting direction

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