Open CASCADE Technology  7.0.0
Public Member Functions | Protected Member Functions | Protected Attributes

IntAna_QuadQuadGeo Class Reference

Geometric intersections between two natural quadrics (Sphere , Cylinder , Cone , Pln from gp). The possible intersections are : More...

#include <IntAna_QuadQuadGeo.hxx>

Public Member Functions

 IntAna_QuadQuadGeo ()
 Empty constructor. More...
 
 IntAna_QuadQuadGeo (const gp_Pln &P1, const gp_Pln &P2, const Standard_Real TolAng, const Standard_Real Tol)
 Creates the intersection between two planes. TolAng is the angular tolerance used to determine if the planes are parallel. Tol is the tolerance used to determine if the planes are identical (only when they are parallel). More...
 
void Perform (const gp_Pln &P1, const gp_Pln &P2, const Standard_Real TolAng, const Standard_Real Tol)
 Intersects two planes. TolAng is the angular tolerance used to determine if the planes are parallel. Tol is the tolerance used to determine if the planes are identical (only when they are parallel). More...
 
 IntAna_QuadQuadGeo (const gp_Pln &P, const gp_Cylinder &C, const Standard_Real Tolang, const Standard_Real Tol, const Standard_Real H=0)
 Creates the intersection between a plane and a cylinder. TolAng is the angular tolerance used to determine if the axis of the cylinder is parallel to the plane. Tol is the tolerance used to determine if the result is a circle or an ellipse. If the maximum distance between the ellipse solution and the circle centered at the ellipse center is less than Tol, the result will be the circle. H is the height of the cylinder <Cyl>. It is used to check whether the plane and cylinder are parallel. More...
 
void Perform (const gp_Pln &P, const gp_Cylinder &C, const Standard_Real Tolang, const Standard_Real Tol, const Standard_Real H=0)
 Intersects a plane and a cylinder. TolAng is the angular tolerance used to determine if the axis of the cylinder is parallel to the plane. Tol is the tolerance used to determine if the result is a circle or an ellipse. If the maximum distance between the ellipse solution and the circle centered at the ellipse center is less than Tol, the result will be the circle. H is the height of the cylinder <Cyl>. It is used to check whether the plane and cylinder are parallel. More...
 
 IntAna_QuadQuadGeo (const gp_Pln &P, const gp_Sphere &S)
 Creates the intersection between a plane and a sphere. More...
 
void Perform (const gp_Pln &P, const gp_Sphere &S)
 Intersects a plane and a sphere. More...
 
 IntAna_QuadQuadGeo (const gp_Pln &P, const gp_Cone &C, const Standard_Real Tolang, const Standard_Real Tol)
 Creates the intersection between a plane and a cone. TolAng is the angular tolerance used to determine if the axis of the cone is parallel or perpendicular to the plane, and if the generating line of the cone is parallel to the plane. Tol is the tolerance used to determine if the apex of the cone is in the plane. More...
 
void Perform (const gp_Pln &P, const gp_Cone &C, const Standard_Real Tolang, const Standard_Real Tol)
 Intersects a plane and a cone. TolAng is the angular tolerance used to determine if the axis of the cone is parallel or perpendicular to the plane, and if the generating line of the cone is parallel to the plane. Tol is the tolerance used to determine if the apex of the cone is in the plane. More...
 
 IntAna_QuadQuadGeo (const gp_Cylinder &Cyl1, const gp_Cylinder &Cyl2, const Standard_Real Tol)
 Creates the intersection between two cylinders. More...
 
void Perform (const gp_Cylinder &Cyl1, const gp_Cylinder &Cyl2, const Standard_Real Tol)
 Intersects two cylinders. More...
 
 IntAna_QuadQuadGeo (const gp_Cylinder &Cyl, const gp_Sphere &Sph, const Standard_Real Tol)
 Creates the intersection between a Cylinder and a Sphere. More...
 
void Perform (const gp_Cylinder &Cyl, const gp_Sphere &Sph, const Standard_Real Tol)
 Intersects a cylinder and a sphere. More...
 
 IntAna_QuadQuadGeo (const gp_Cylinder &Cyl, const gp_Cone &Con, const Standard_Real Tol)
 Creates the intersection between a Cylinder and a Cone. More...
 
void Perform (const gp_Cylinder &Cyl, const gp_Cone &Con, const Standard_Real Tol)
 Intersects a cylinder and a cone. More...
 
 IntAna_QuadQuadGeo (const gp_Sphere &Sph1, const gp_Sphere &Sph2, const Standard_Real Tol)
 Creates the intersection between two Spheres. More...
 
void Perform (const gp_Sphere &Sph1, const gp_Sphere &Sph2, const Standard_Real Tol)
 Intersects a two spheres. More...
 
 IntAna_QuadQuadGeo (const gp_Sphere &Sph, const gp_Cone &Con, const Standard_Real Tol)
 Creates the intersection beween a Sphere and a Cone. More...
 
void Perform (const gp_Sphere &Sph, const gp_Cone &Con, const Standard_Real Tol)
 Intersects a sphere and a cone. More...
 
 IntAna_QuadQuadGeo (const gp_Cone &Con1, const gp_Cone &Con2, const Standard_Real Tol)
 Creates the intersection beween two cones. More...
 
void Perform (const gp_Cone &Con1, const gp_Cone &Con2, const Standard_Real Tol)
 Intersects two cones. More...
 
 IntAna_QuadQuadGeo (const gp_Pln &Pln, const gp_Torus &Tor, const Standard_Real Tol)
 Creates the intersection beween plane and torus. More...
 
void Perform (const gp_Pln &Pln, const gp_Torus &Tor, const Standard_Real Tol)
 Intersects plane and torus. More...
 
 IntAna_QuadQuadGeo (const gp_Cylinder &Cyl, const gp_Torus &Tor, const Standard_Real Tol)
 Creates the intersection beween cylinder and torus. More...
 
void Perform (const gp_Cylinder &Cyl, const gp_Torus &Tor, const Standard_Real Tol)
 Intersects cylinder and torus. More...
 
 IntAna_QuadQuadGeo (const gp_Cone &Con, const gp_Torus &Tor, const Standard_Real Tol)
 Creates the intersection beween cone and torus. More...
 
void Perform (const gp_Cone &Con, const gp_Torus &Tor, const Standard_Real Tol)
 Intersects cone and torus. More...
 
 IntAna_QuadQuadGeo (const gp_Sphere &Sph, const gp_Torus &Tor, const Standard_Real Tol)
 Creates the intersection beween sphere and torus. More...
 
void Perform (const gp_Sphere &Sph, const gp_Torus &Tor, const Standard_Real Tol)
 Intersects sphere and torus. More...
 
 IntAna_QuadQuadGeo (const gp_Torus &Tor1, const gp_Torus &Tor2, const Standard_Real Tol)
 Creates the intersection beween two toruses. More...
 
void Perform (const gp_Torus &Tor1, const gp_Torus &Tor2, const Standard_Real Tol)
 Intersects two toruses. More...
 
Standard_Boolean IsDone () const
 Returns Standard_True if the computation was successful. More...
 
IntAna_ResultType TypeInter () const
 Returns the type of intersection. More...
 
Standard_Integer NbSolutions () const
 Returns the number of interesections. The possible intersections are : More...
 
gp_Pnt Point (const Standard_Integer Num) const
 Returns the point solution of range Num. More...
 
gp_Lin Line (const Standard_Integer Num) const
 Returns the line solution of range Num. More...
 
gp_Circ Circle (const Standard_Integer Num) const
 Returns the circle solution of range Num. More...
 
gp_Elips Ellipse (const Standard_Integer Num) const
 Returns the ellipse solution of range Num. More...
 
gp_Parab Parabola (const Standard_Integer Num) const
 Returns the parabola solution of range Num. More...
 
gp_Hypr Hyperbola (const Standard_Integer Num) const
 Returns the hyperbola solution of range Num. More...
 
Standard_Boolean HasCommonGen () const
 
const gp_PntPChar () const
 

Protected Member Functions

void InitTolerances ()
 Initialize the values of inner tolerances. More...
 

Protected Attributes

Standard_Boolean done
 
Standard_Integer nbint
 
IntAna_ResultType typeres
 
gp_Pnt pt1
 
gp_Pnt pt2
 
gp_Pnt pt3
 
gp_Pnt pt4
 
gp_Dir dir1
 
gp_Dir dir2
 
gp_Dir dir3
 
gp_Dir dir4
 
Standard_Real param1
 
Standard_Real param2
 
Standard_Real param3
 
Standard_Real param4
 
Standard_Real param1bis
 
Standard_Real param2bis
 
Standard_Real myEPSILON_DISTANCE
 
Standard_Real myEPSILON_ANGLE_CONE
 
Standard_Real myEPSILON_MINI_CIRCLE_RADIUS
 
Standard_Real myEPSILON_CYLINDER_DELTA_RADIUS
 
Standard_Real myEPSILON_CYLINDER_DELTA_DISTANCE
 
Standard_Real myEPSILON_AXES_PARA
 
Standard_Boolean myCommonGen
 
gp_Pnt myPChar
 

Detailed Description

Geometric intersections between two natural quadrics (Sphere , Cylinder , Cone , Pln from gp). The possible intersections are :

Constructor & Destructor Documentation

IntAna_QuadQuadGeo::IntAna_QuadQuadGeo ( )

Empty constructor.

IntAna_QuadQuadGeo::IntAna_QuadQuadGeo ( const gp_Pln P1,
const gp_Pln P2,
const Standard_Real  TolAng,
const Standard_Real  Tol 
)

Creates the intersection between two planes. TolAng is the angular tolerance used to determine if the planes are parallel. Tol is the tolerance used to determine if the planes are identical (only when they are parallel).

IntAna_QuadQuadGeo::IntAna_QuadQuadGeo ( const gp_Pln P,
const gp_Cylinder C,
const Standard_Real  Tolang,
const Standard_Real  Tol,
const Standard_Real  H = 0 
)

Creates the intersection between a plane and a cylinder. TolAng is the angular tolerance used to determine if the axis of the cylinder is parallel to the plane. Tol is the tolerance used to determine if the result is a circle or an ellipse. If the maximum distance between the ellipse solution and the circle centered at the ellipse center is less than Tol, the result will be the circle. H is the height of the cylinder <Cyl>. It is used to check whether the plane and cylinder are parallel.

IntAna_QuadQuadGeo::IntAna_QuadQuadGeo ( const gp_Pln P,
const gp_Sphere S 
)

Creates the intersection between a plane and a sphere.

IntAna_QuadQuadGeo::IntAna_QuadQuadGeo ( const gp_Pln P,
const gp_Cone C,
const Standard_Real  Tolang,
const Standard_Real  Tol 
)

Creates the intersection between a plane and a cone. TolAng is the angular tolerance used to determine if the axis of the cone is parallel or perpendicular to the plane, and if the generating line of the cone is parallel to the plane. Tol is the tolerance used to determine if the apex of the cone is in the plane.

IntAna_QuadQuadGeo::IntAna_QuadQuadGeo ( const gp_Cylinder Cyl1,
const gp_Cylinder Cyl2,
const Standard_Real  Tol 
)

Creates the intersection between two cylinders.

IntAna_QuadQuadGeo::IntAna_QuadQuadGeo ( const gp_Cylinder Cyl,
const gp_Sphere Sph,
const Standard_Real  Tol 
)

Creates the intersection between a Cylinder and a Sphere.

IntAna_QuadQuadGeo::IntAna_QuadQuadGeo ( const gp_Cylinder Cyl,
const gp_Cone Con,
const Standard_Real  Tol 
)

Creates the intersection between a Cylinder and a Cone.

IntAna_QuadQuadGeo::IntAna_QuadQuadGeo ( const gp_Sphere Sph1,
const gp_Sphere Sph2,
const Standard_Real  Tol 
)

Creates the intersection between two Spheres.

IntAna_QuadQuadGeo::IntAna_QuadQuadGeo ( const gp_Sphere Sph,
const gp_Cone Con,
const Standard_Real  Tol 
)

Creates the intersection beween a Sphere and a Cone.

IntAna_QuadQuadGeo::IntAna_QuadQuadGeo ( const gp_Cone Con1,
const gp_Cone Con2,
const Standard_Real  Tol 
)

Creates the intersection beween two cones.

IntAna_QuadQuadGeo::IntAna_QuadQuadGeo ( const gp_Pln Pln,
const gp_Torus Tor,
const Standard_Real  Tol 
)

Creates the intersection beween plane and torus.

IntAna_QuadQuadGeo::IntAna_QuadQuadGeo ( const gp_Cylinder Cyl,
const gp_Torus Tor,
const Standard_Real  Tol 
)

Creates the intersection beween cylinder and torus.

IntAna_QuadQuadGeo::IntAna_QuadQuadGeo ( const gp_Cone Con,
const gp_Torus Tor,
const Standard_Real  Tol 
)

Creates the intersection beween cone and torus.

IntAna_QuadQuadGeo::IntAna_QuadQuadGeo ( const gp_Sphere Sph,
const gp_Torus Tor,
const Standard_Real  Tol 
)

Creates the intersection beween sphere and torus.

IntAna_QuadQuadGeo::IntAna_QuadQuadGeo ( const gp_Torus Tor1,
const gp_Torus Tor2,
const Standard_Real  Tol 
)

Creates the intersection beween two toruses.

Member Function Documentation

gp_Circ IntAna_QuadQuadGeo::Circle ( const Standard_Integer  Num) const

Returns the circle solution of range Num.

gp_Elips IntAna_QuadQuadGeo::Ellipse ( const Standard_Integer  Num) const

Returns the ellipse solution of range Num.

Standard_Boolean IntAna_QuadQuadGeo::HasCommonGen ( ) const
gp_Hypr IntAna_QuadQuadGeo::Hyperbola ( const Standard_Integer  Num) const

Returns the hyperbola solution of range Num.

void IntAna_QuadQuadGeo::InitTolerances ( )
protected

Initialize the values of inner tolerances.

Standard_Boolean IntAna_QuadQuadGeo::IsDone ( ) const

Returns Standard_True if the computation was successful.

gp_Lin IntAna_QuadQuadGeo::Line ( const Standard_Integer  Num) const

Returns the line solution of range Num.

Standard_Integer IntAna_QuadQuadGeo::NbSolutions ( ) const

Returns the number of interesections. The possible intersections are :

  • 1 point
  • 1 or 2 line(s)
  • 1 Point and 1 Line
  • 1 circle
  • 1 ellipse
  • 1 parabola
  • 1 or 2 hyperbola(s).
gp_Parab IntAna_QuadQuadGeo::Parabola ( const Standard_Integer  Num) const

Returns the parabola solution of range Num.

const gp_Pnt& IntAna_QuadQuadGeo::PChar ( ) const
void IntAna_QuadQuadGeo::Perform ( const gp_Pln P1,
const gp_Pln P2,
const Standard_Real  TolAng,
const Standard_Real  Tol 
)

Intersects two planes. TolAng is the angular tolerance used to determine if the planes are parallel. Tol is the tolerance used to determine if the planes are identical (only when they are parallel).

void IntAna_QuadQuadGeo::Perform ( const gp_Pln P,
const gp_Cylinder C,
const Standard_Real  Tolang,
const Standard_Real  Tol,
const Standard_Real  H = 0 
)

Intersects a plane and a cylinder. TolAng is the angular tolerance used to determine if the axis of the cylinder is parallel to the plane. Tol is the tolerance used to determine if the result is a circle or an ellipse. If the maximum distance between the ellipse solution and the circle centered at the ellipse center is less than Tol, the result will be the circle. H is the height of the cylinder <Cyl>. It is used to check whether the plane and cylinder are parallel.

void IntAna_QuadQuadGeo::Perform ( const gp_Pln P,
const gp_Sphere S 
)

Intersects a plane and a sphere.

void IntAna_QuadQuadGeo::Perform ( const gp_Pln P,
const gp_Cone C,
const Standard_Real  Tolang,
const Standard_Real  Tol 
)

Intersects a plane and a cone. TolAng is the angular tolerance used to determine if the axis of the cone is parallel or perpendicular to the plane, and if the generating line of the cone is parallel to the plane. Tol is the tolerance used to determine if the apex of the cone is in the plane.

void IntAna_QuadQuadGeo::Perform ( const gp_Cylinder Cyl1,
const gp_Cylinder Cyl2,
const Standard_Real  Tol 
)

Intersects two cylinders.

void IntAna_QuadQuadGeo::Perform ( const gp_Cylinder Cyl,
const gp_Sphere Sph,
const Standard_Real  Tol 
)

Intersects a cylinder and a sphere.

void IntAna_QuadQuadGeo::Perform ( const gp_Cylinder Cyl,
const gp_Cone Con,
const Standard_Real  Tol 
)

Intersects a cylinder and a cone.

void IntAna_QuadQuadGeo::Perform ( const gp_Sphere Sph1,
const gp_Sphere Sph2,
const Standard_Real  Tol 
)

Intersects a two spheres.

void IntAna_QuadQuadGeo::Perform ( const gp_Sphere Sph,
const gp_Cone Con,
const Standard_Real  Tol 
)

Intersects a sphere and a cone.

void IntAna_QuadQuadGeo::Perform ( const gp_Cone Con1,
const gp_Cone Con2,
const Standard_Real  Tol 
)

Intersects two cones.

void IntAna_QuadQuadGeo::Perform ( const gp_Pln Pln,
const gp_Torus Tor,
const Standard_Real  Tol 
)

Intersects plane and torus.

void IntAna_QuadQuadGeo::Perform ( const gp_Cylinder Cyl,
const gp_Torus Tor,
const Standard_Real  Tol 
)

Intersects cylinder and torus.

void IntAna_QuadQuadGeo::Perform ( const gp_Cone Con,
const gp_Torus Tor,
const Standard_Real  Tol 
)

Intersects cone and torus.

void IntAna_QuadQuadGeo::Perform ( const gp_Sphere Sph,
const gp_Torus Tor,
const Standard_Real  Tol 
)

Intersects sphere and torus.

void IntAna_QuadQuadGeo::Perform ( const gp_Torus Tor1,
const gp_Torus Tor2,
const Standard_Real  Tol 
)

Intersects two toruses.

gp_Pnt IntAna_QuadQuadGeo::Point ( const Standard_Integer  Num) const

Returns the point solution of range Num.

IntAna_ResultType IntAna_QuadQuadGeo::TypeInter ( ) const

Returns the type of intersection.

Field Documentation

gp_Dir IntAna_QuadQuadGeo::dir1
protected
gp_Dir IntAna_QuadQuadGeo::dir2
protected
gp_Dir IntAna_QuadQuadGeo::dir3
protected
gp_Dir IntAna_QuadQuadGeo::dir4
protected
Standard_Boolean IntAna_QuadQuadGeo::done
protected
Standard_Boolean IntAna_QuadQuadGeo::myCommonGen
protected
Standard_Real IntAna_QuadQuadGeo::myEPSILON_ANGLE_CONE
protected
Standard_Real IntAna_QuadQuadGeo::myEPSILON_AXES_PARA
protected
Standard_Real IntAna_QuadQuadGeo::myEPSILON_CYLINDER_DELTA_DISTANCE
protected
Standard_Real IntAna_QuadQuadGeo::myEPSILON_CYLINDER_DELTA_RADIUS
protected
Standard_Real IntAna_QuadQuadGeo::myEPSILON_DISTANCE
protected
Standard_Real IntAna_QuadQuadGeo::myEPSILON_MINI_CIRCLE_RADIUS
protected
gp_Pnt IntAna_QuadQuadGeo::myPChar
protected
Standard_Integer IntAna_QuadQuadGeo::nbint
protected
Standard_Real IntAna_QuadQuadGeo::param1
protected
Standard_Real IntAna_QuadQuadGeo::param1bis
protected
Standard_Real IntAna_QuadQuadGeo::param2
protected
Standard_Real IntAna_QuadQuadGeo::param2bis
protected
Standard_Real IntAna_QuadQuadGeo::param3
protected
Standard_Real IntAna_QuadQuadGeo::param4
protected
gp_Pnt IntAna_QuadQuadGeo::pt1
protected
gp_Pnt IntAna_QuadQuadGeo::pt2
protected
gp_Pnt IntAna_QuadQuadGeo::pt3
protected
gp_Pnt IntAna_QuadQuadGeo::pt4
protected
IntAna_ResultType IntAna_QuadQuadGeo::typeres
protected

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