1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-04-08 18:40:55 +03:00
occt/src/GeomInt/GeomInt_IntSS.lxx
bugmaster b311480ed5 0023024: Update headers of OCCT files
Added appropriate copyright and license information in source files
2012-03-21 19:43:04 +04:00

153 lines
5.8 KiB
Plaintext
Executable File

// Created on: 1995-01-27
// Created by: Jacques GOUSSARD
// Copyright (c) 1995-1999 Matra Datavision
// Copyright (c) 1999-2012 OPEN CASCADE SAS
//
// The content of this file is subject to the Open CASCADE Technology Public
// License Version 6.5 (the "License"). You may not use the content of this file
// except in compliance with the License. Please obtain a copy of the License
// at http://www.opencascade.org and read it completely before using this file.
//
// The Initial Developer of the Original Code is Open CASCADE S.A.S., having its
// main offices at: 1, place des Freres Montgolfier, 78280 Guyancourt, France.
//
// The Original Code and all software distributed under the License is
// distributed on an "AS IS" basis, without warranty of any kind, and the
// Initial Developer hereby disclaims all such warranties, including without
// limitation, any warranties of merchantability, fitness for a particular
// purpose or non-infringement. Please see the License for the specific terms
// and conditions governing the rights and limitations under the License.
#include <IntPatch_Point.hxx>
//=======================================================================
//function : GeomInt_IntSS
//purpose :
//=======================================================================
inline GeomInt_IntSS::GeomInt_IntSS ()
: myNbrestr(0),
myTolReached2d(0.0),
myTolReached3d(0.0),
myTolCheck(0.0000001),
myTolAngCheck(0.3)
{}
//=======================================================================
//function : GeomInt_IntSS
//purpose :
//=======================================================================
inline GeomInt_IntSS::GeomInt_IntSS (const Handle(Geom_Surface)& S1,
const Handle(Geom_Surface)& S2,
const Standard_Real Tol,
const Standard_Boolean Approx,
const Standard_Boolean ApproxS1,
const Standard_Boolean ApproxS2)
: myNbrestr(0),
myTolReached2d(0.0),
myTolReached3d(0.0),
myTolCheck(0.0000001),
myTolAngCheck(0.3)
{
Perform(S1,S2,Tol,Approx,ApproxS1,ApproxS2);
}
//=======================================================================
//function : Perform
//purpose : Intersection of Adapted surfaces
//=======================================================================
inline void GeomInt_IntSS::Perform(const Handle(GeomAdaptor_HSurface)& HS1,
const Handle(GeomAdaptor_HSurface)& HS2,
const Standard_Real Tol,
const Standard_Boolean Approx,
const Standard_Boolean ApproxS1,
const Standard_Boolean ApproxS2)
{
myHS1 = HS1;
myHS2 = HS2;
InternalPerform(Tol,Approx,ApproxS1,ApproxS2,Standard_False,0.,0.,0.,0.);
}
//=======================================================================
//function : Perform
//purpose : Intersection of Adapted surfaces with a Starting Point
//=======================================================================
inline void GeomInt_IntSS::Perform(const Handle(GeomAdaptor_HSurface)& HS1,
const Handle(GeomAdaptor_HSurface)& HS2,
const Standard_Real Tol,
const Standard_Real U1, const Standard_Real V1,
const Standard_Real U2, const Standard_Real V2,
const Standard_Boolean Approx,
const Standard_Boolean ApproxS1,
const Standard_Boolean ApproxS2)
{
myHS1 = HS1;
myHS2 = HS2;
InternalPerform(Tol,Approx,ApproxS1,ApproxS2,Standard_True,U1,V1,U2,V2);
}
//=======================================================================
//function : IsDone
//purpose :
//=======================================================================
inline Standard_Boolean GeomInt_IntSS::IsDone () const
{
return myIntersector.IsDone();
}
//=======================================================================
//function : TolReached2d
//purpose :
//=======================================================================
inline Standard_Real GeomInt_IntSS::TolReached2d () const
{
return myTolReached2d;
}
//=======================================================================
//function : TolReached3d
//purpose :
//=======================================================================
inline Standard_Real GeomInt_IntSS::TolReached3d () const
{
return myTolReached3d;
}
//=======================================================================
//function : NbLines
//purpose :
//=======================================================================
inline Standard_Integer GeomInt_IntSS::NbLines () const
{
return sline.Length()-myNbrestr;
}
//=======================================================================
//function : NbBoundaries
//purpose :
//=======================================================================
inline Standard_Integer GeomInt_IntSS::NbBoundaries () const
{
StdFail_NotDone_Raise_if(!myIntersector.IsDone(),"");
return myNbrestr;
}
//=======================================================================
//function : NbPoints
//purpose :
//=======================================================================
inline Standard_Integer GeomInt_IntSS::NbPoints () const
{
return myIntersector.NbPnts();
}
//=======================================================================
//function : Point
//purpose :
//=======================================================================
inline gp_Pnt GeomInt_IntSS::Point (const Standard_Integer Index) const
{
return myIntersector.Point(Index).Value();
}