mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-14 13:30:48 +03:00
0022826: Increasiong of perfomance of fixes applied during translation of STEP files.
Modification draw command "proj" and class GeomAPI_ProjectPointOnSurf: adding the ability to use UBTree algorithm to find projection in Extrema_GenExtPS.
This commit is contained in:
@@ -30,6 +30,7 @@ class ProjectPointOnSurf from GeomAPI
|
||||
uses
|
||||
Surface from Geom,
|
||||
ExtPS from Extrema,
|
||||
ExtAlgo from Extrema,
|
||||
Pnt from gp,
|
||||
Length from Quantity,
|
||||
Parameter from Quantity,
|
||||
@@ -50,7 +51,8 @@ is
|
||||
|
||||
|
||||
Create(P : Pnt from gp;
|
||||
Surface : Surface from Geom)
|
||||
Surface : Surface from Geom;
|
||||
Algo : ExtAlgo from Extrema = Extrema_ExtAlgo_Grad)
|
||||
---Purpose: Create the projection of a point <P> on a surface
|
||||
-- <Surface>
|
||||
---Level: Public
|
||||
@@ -58,7 +60,8 @@ is
|
||||
|
||||
Create(P : Pnt from gp;
|
||||
Surface : Surface from Geom;
|
||||
Tolerance : Real from Standard)
|
||||
Tolerance : Real from Standard;
|
||||
Algo : ExtAlgo from Extrema = Extrema_ExtAlgo_Grad)
|
||||
---Purpose: Create the projection of a point <P> on a surface
|
||||
-- <Surface>
|
||||
---Level: Public
|
||||
@@ -74,13 +77,15 @@ is
|
||||
Surface : Surface from Geom;
|
||||
Umin, Usup,
|
||||
Vmin, Vsup : Parameter from Quantity;
|
||||
Tolerance : Real from Standard)
|
||||
Tolerance : Real from Standard;
|
||||
Algo : ExtAlgo from Extrema = Extrema_ExtAlgo_Grad)
|
||||
returns ProjectPointOnSurf from GeomAPI;
|
||||
|
||||
Create(P : Pnt from gp;
|
||||
Surface : Surface from Geom;
|
||||
Umin, Usup,
|
||||
Vmin, Vsup : Parameter from Quantity)
|
||||
Vmin, Vsup : Parameter from Quantity;
|
||||
Algo : ExtAlgo from Extrema = Extrema_ExtAlgo_Grad)
|
||||
returns ProjectPointOnSurf from GeomAPI;
|
||||
|
||||
|
||||
@@ -91,12 +96,14 @@ is
|
||||
Init(me : in out;
|
||||
P : Pnt from gp;
|
||||
Surface : Surface from Geom;
|
||||
Tolerance : Real from Standard)
|
||||
Tolerance : Real from Standard;
|
||||
Algo : ExtAlgo from Extrema = Extrema_ExtAlgo_Grad)
|
||||
is static;
|
||||
|
||||
Init(me : in out;
|
||||
P : Pnt from gp;
|
||||
Surface : Surface from Geom)
|
||||
Surface : Surface from Geom;
|
||||
Algo : ExtAlgo from Extrema = Extrema_ExtAlgo_Grad)
|
||||
is static;
|
||||
|
||||
|
||||
@@ -110,7 +117,8 @@ is
|
||||
Surface : Surface from Geom;
|
||||
Umin, Usup,
|
||||
Vmin, Vsup : Parameter from Quantity;
|
||||
Tolerance : Real from Standard)
|
||||
Tolerance : Real from Standard;
|
||||
Algo : ExtAlgo from Extrema = Extrema_ExtAlgo_Grad)
|
||||
---Level: Public
|
||||
is static;
|
||||
|
||||
@@ -118,7 +126,8 @@ is
|
||||
P : Pnt from gp;
|
||||
Surface : Surface from Geom;
|
||||
Umin, Usup,
|
||||
Vmin, Vsup : Parameter from Quantity)
|
||||
Vmin, Vsup : Parameter from Quantity;
|
||||
Algo : ExtAlgo from Extrema = Extrema_ExtAlgo_Grad)
|
||||
is static;
|
||||
|
||||
|
||||
@@ -131,13 +140,15 @@ is
|
||||
Surface : Surface from Geom;
|
||||
Umin, Usup,
|
||||
Vmin, Vsup : Parameter from Quantity;
|
||||
Tolerance : Real from Standard)
|
||||
Tolerance : Real from Standard;
|
||||
Algo : ExtAlgo from Extrema = Extrema_ExtAlgo_Grad)
|
||||
is static;
|
||||
|
||||
Init(me : in out;
|
||||
Surface : Surface from Geom;
|
||||
Umin, Usup,
|
||||
Vmin, Vsup : Parameter from Quantity)
|
||||
Vmin, Vsup : Parameter from Quantity;
|
||||
Algo : ExtAlgo from Extrema = Extrema_ExtAlgo_Grad)
|
||||
is static;
|
||||
|
||||
|
||||
|
@@ -39,9 +39,10 @@ GeomAPI_ProjectPointOnSurf::GeomAPI_ProjectPointOnSurf()
|
||||
//purpose :
|
||||
//=======================================================================
|
||||
GeomAPI_ProjectPointOnSurf::GeomAPI_ProjectPointOnSurf (const gp_Pnt& P,
|
||||
const Handle(Geom_Surface)& Surface)
|
||||
const Handle(Geom_Surface)& Surface,
|
||||
const Extrema_ExtAlgo theProjAlgo)
|
||||
{
|
||||
Init (P, Surface);
|
||||
Init (P, Surface, theProjAlgo);
|
||||
}
|
||||
//=======================================================================
|
||||
//function : GeomAPI_ProjectPointOnSurf
|
||||
@@ -49,9 +50,10 @@ GeomAPI_ProjectPointOnSurf::GeomAPI_ProjectPointOnSurf()
|
||||
//=======================================================================
|
||||
GeomAPI_ProjectPointOnSurf::GeomAPI_ProjectPointOnSurf (const gp_Pnt& P,
|
||||
const Handle(Geom_Surface)& Surface,
|
||||
const Standard_Real Tolerance)
|
||||
const Standard_Real Tolerance,
|
||||
const Extrema_ExtAlgo theProjAlgo)
|
||||
{
|
||||
Init (P, Surface, Tolerance);
|
||||
Init (P, Surface, Tolerance, theProjAlgo);
|
||||
}
|
||||
//=======================================================================
|
||||
//function : GeomAPI_ProjectPointOnSurf
|
||||
@@ -62,10 +64,11 @@ GeomAPI_ProjectPointOnSurf::GeomAPI_ProjectPointOnSurf()
|
||||
const Standard_Real Umin,
|
||||
const Standard_Real Usup,
|
||||
const Standard_Real Vmin,
|
||||
const Standard_Real Vsup)
|
||||
const Standard_Real Vsup,
|
||||
const Extrema_ExtAlgo theProjAlgo)
|
||||
|
||||
{
|
||||
Init (P, Surface, Umin, Usup, Vmin, Vsup);
|
||||
Init (P, Surface, Umin, Usup, Vmin, Vsup, theProjAlgo);
|
||||
}
|
||||
//=======================================================================
|
||||
//function : GeomAPI_ProjectPointOnSurf
|
||||
@@ -77,10 +80,11 @@ GeomAPI_ProjectPointOnSurf::GeomAPI_ProjectPointOnSurf()
|
||||
const Standard_Real Usup,
|
||||
const Standard_Real Vmin,
|
||||
const Standard_Real Vsup,
|
||||
const Standard_Real Tolerance)
|
||||
const Standard_Real Tolerance,
|
||||
const Extrema_ExtAlgo theProjAlgo)
|
||||
|
||||
{
|
||||
Init (P, Surface, Umin, Usup, Vmin, Vsup, Tolerance);
|
||||
Init (P, Surface, Umin, Usup, Vmin, Vsup, Tolerance, theProjAlgo);
|
||||
}
|
||||
//=======================================================================
|
||||
//function : Init
|
||||
@@ -109,10 +113,11 @@ GeomAPI_ProjectPointOnSurf::GeomAPI_ProjectPointOnSurf()
|
||||
//purpose :
|
||||
//=======================================================================
|
||||
void GeomAPI_ProjectPointOnSurf::Init (const gp_Pnt& P,
|
||||
const Handle(Geom_Surface)& Surface)
|
||||
const Handle(Geom_Surface)& Surface,
|
||||
const Extrema_ExtAlgo theProjAlgo)
|
||||
|
||||
{
|
||||
Init (P, Surface, Precision::Confusion());
|
||||
Init (P, Surface, Precision::Confusion(), theProjAlgo);
|
||||
}
|
||||
//=======================================================================
|
||||
//function : Init
|
||||
@@ -120,7 +125,8 @@ GeomAPI_ProjectPointOnSurf::GeomAPI_ProjectPointOnSurf()
|
||||
//=======================================================================
|
||||
void GeomAPI_ProjectPointOnSurf::Init(const gp_Pnt& P,
|
||||
const Handle(Geom_Surface)& Surface,
|
||||
const Standard_Real Tolerance)
|
||||
const Standard_Real Tolerance,
|
||||
const Extrema_ExtAlgo theProjAlgo)
|
||||
|
||||
{
|
||||
//modified by NIZNHY-PKV Thu Apr 4 10:37:55 2002 f
|
||||
@@ -133,6 +139,7 @@ GeomAPI_ProjectPointOnSurf::GeomAPI_ProjectPointOnSurf()
|
||||
myGeomAdaptor.Load(Surface, Umin, Usup, Vmin, Vsup);
|
||||
//
|
||||
//myExtPS = Extrema_ExtPS();
|
||||
myExtPS.SetAlgo(theProjAlgo);
|
||||
myExtPS.Initialize(myGeomAdaptor, Umin, Usup, Vmin, Vsup, Tolerance, Tolerance);
|
||||
myExtPS.Perform(P);
|
||||
//XXXmyExtPS = Extrema_ExtPS (P, myGeomAdaptor, Tolerance, Tolerance);
|
||||
@@ -152,7 +159,8 @@ GeomAPI_ProjectPointOnSurf::GeomAPI_ProjectPointOnSurf()
|
||||
const Standard_Real Umin,
|
||||
const Standard_Real Usup,
|
||||
const Standard_Real Vmin,
|
||||
const Standard_Real Vsup )
|
||||
const Standard_Real Vsup,
|
||||
const Extrema_ExtAlgo theProjAlgo)
|
||||
{
|
||||
Standard_Real Tolerance = Precision::PConfusion();
|
||||
//modified by NIZNHY-PKV Thu Apr 4 10:38:23 2002 f
|
||||
@@ -160,6 +168,7 @@ GeomAPI_ProjectPointOnSurf::GeomAPI_ProjectPointOnSurf()
|
||||
//myExtPS = Extrema_ExtPS (P, TheSurface, Tol, Tol);
|
||||
myGeomAdaptor.Load(Surface, Umin,Usup,Vmin,Vsup);
|
||||
//myExtPS = Extrema_ExtPS();
|
||||
myExtPS.SetAlgo(theProjAlgo);
|
||||
myExtPS.Initialize(myGeomAdaptor, Umin, Usup, Vmin, Vsup, Tolerance, Tolerance);
|
||||
myExtPS.Perform(P);
|
||||
//XXX myExtPS = Extrema_ExtPS (P, myGeomAdaptor, Tol, Tol);
|
||||
@@ -177,13 +186,15 @@ GeomAPI_ProjectPointOnSurf::GeomAPI_ProjectPointOnSurf()
|
||||
const Standard_Real Usup,
|
||||
const Standard_Real Vmin,
|
||||
const Standard_Real Vsup,
|
||||
const Standard_Real Tolerance)
|
||||
const Standard_Real Tolerance,
|
||||
const Extrema_ExtAlgo theProjAlgo)
|
||||
{
|
||||
//modified by NIZNHY-PKV Thu Apr 4 10:39:10 2002 f
|
||||
//GeomAdaptor_Surface TheSurface (Surface,Umin,Usup,Vmin,Vsup);
|
||||
//myExtPS = Extrema_ExtPS (P, TheSurface, Tolerance, Tolerance);
|
||||
myGeomAdaptor.Load(Surface, Umin,Usup,Vmin,Vsup);
|
||||
//myExtPS = Extrema_ExtPS();
|
||||
myExtPS.SetAlgo(theProjAlgo);
|
||||
myExtPS.Initialize(myGeomAdaptor, Umin, Usup, Vmin, Vsup, Tolerance, Tolerance);
|
||||
myExtPS.Perform(P);
|
||||
//XXX myExtPS = Extrema_ExtPS (P, myGeomAdaptor, Tolerance, Tolerance);
|
||||
@@ -198,7 +209,8 @@ GeomAPI_ProjectPointOnSurf::GeomAPI_ProjectPointOnSurf()
|
||||
const Standard_Real Umin,
|
||||
const Standard_Real Usup,
|
||||
const Standard_Real Vmin,
|
||||
const Standard_Real Vsup )
|
||||
const Standard_Real Vsup,
|
||||
const Extrema_ExtAlgo theProjAlgo)
|
||||
{
|
||||
Standard_Real Tolerance = Precision::PConfusion();
|
||||
//modified by NIZNHY-PKV Thu Apr 4 10:41:50 2002 f
|
||||
@@ -208,6 +220,7 @@ GeomAPI_ProjectPointOnSurf::GeomAPI_ProjectPointOnSurf()
|
||||
//myExtPS = Extrema_ExtPS();
|
||||
//modified by NIZNHY-PKV Thu Apr 4 10:42:32 2002 f
|
||||
//myExtPS.Initialize(TheSurface, Umin, Usup, Vmin, Vsup, Tol, Tol);
|
||||
myExtPS.SetAlgo(theProjAlgo);
|
||||
myExtPS.Initialize(myGeomAdaptor, Umin, Usup, Vmin, Vsup, Tolerance, Tolerance);
|
||||
//modified by NIZNHY-PKV Thu Apr 4 10:42:39 2002 t
|
||||
myIsDone = Standard_False;
|
||||
@@ -221,7 +234,8 @@ GeomAPI_ProjectPointOnSurf::GeomAPI_ProjectPointOnSurf()
|
||||
const Standard_Real Usup,
|
||||
const Standard_Real Vmin,
|
||||
const Standard_Real Vsup,
|
||||
const Standard_Real Tolerance)
|
||||
const Standard_Real Tolerance,
|
||||
const Extrema_ExtAlgo theProjAlgo)
|
||||
{
|
||||
//modified by NIZNHY-PKV Thu Apr 4 10:43:00 2002 f
|
||||
//GeomAdaptor_Surface TheSurface (Surface,Umin,Usup,Vmin,Vsup);
|
||||
@@ -230,6 +244,7 @@ GeomAPI_ProjectPointOnSurf::GeomAPI_ProjectPointOnSurf()
|
||||
//myExtPS = Extrema_ExtPS();
|
||||
//modified by NIZNHY-PKV Thu Apr 4 10:43:18 2002 f
|
||||
//myExtPS.Initialize(TheSurface, Umin, Usup, Vmin, Vsup, Tolerance, Tolerance);
|
||||
myExtPS.SetAlgo(theProjAlgo);
|
||||
myExtPS.Initialize(myGeomAdaptor, Umin, Usup, Vmin, Vsup, Tolerance, Tolerance);
|
||||
//modified by NIZNHY-PKV Thu Apr 4 10:43:26 2002 t
|
||||
myIsDone = Standard_False;
|
||||
|
Reference in New Issue
Block a user