mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-04-10 18:51:21 +03:00
refs #0024985: control of parameters for Pipe Shell algo
This commit is contained in:
parent
f9823ea65a
commit
c4415f60d1
@ -115,6 +115,19 @@ is
|
|||||||
|
|
||||||
---Level: Public
|
---Level: Public
|
||||||
|
|
||||||
|
|
||||||
|
-- ============================================
|
||||||
|
-- Methods to set parameters for approximation
|
||||||
|
-- ============================================
|
||||||
|
SetMaxDegree(me : mutable;
|
||||||
|
NewMaxDegree : Integer from Standard);
|
||||||
|
---Purpose: Define the maximum V degree of resulting surface
|
||||||
|
|
||||||
|
SetMaxSegments(me : mutable;
|
||||||
|
NewMaxSegments : Integer from Standard);
|
||||||
|
---Purpose: Define the maximum number of spans in V-direction
|
||||||
|
-- on resulting surface
|
||||||
|
|
||||||
SetForceApproxC1(me : mutable;
|
SetForceApproxC1(me : mutable;
|
||||||
ForceApproxC1 : Boolean from Standard);
|
ForceApproxC1 : Boolean from Standard);
|
||||||
---Purpose: Set the flag that indicates attempt to approximate
|
---Purpose: Set the flag that indicates attempt to approximate
|
||||||
@ -289,6 +302,8 @@ fields
|
|||||||
myBoundTol : Real;
|
myBoundTol : Real;
|
||||||
myTolAngular : Real;
|
myTolAngular : Real;
|
||||||
angmin, angmax : Real;
|
angmin, angmax : Real;
|
||||||
|
myMaxDegree : Integer;
|
||||||
|
myMaxSegments : Integer;
|
||||||
myForceApproxC1 : Boolean;
|
myForceApproxC1 : Boolean;
|
||||||
|
|
||||||
myLaw : Function from Law;
|
myLaw : Function from Law;
|
||||||
|
@ -226,6 +226,9 @@ BRepFill_PipeShell::BRepFill_PipeShell(const TopoDS_Wire& Spine)
|
|||||||
myLaw.Nullify();
|
myLaw.Nullify();
|
||||||
SetTolerance();
|
SetTolerance();
|
||||||
|
|
||||||
|
myMaxDegree = 11;
|
||||||
|
myMaxSegments = 30;
|
||||||
|
|
||||||
// Attention to closed non-declared wire !
|
// Attention to closed non-declared wire !
|
||||||
if (!mySpine.Closed()) {
|
if (!mySpine.Closed()) {
|
||||||
TopoDS_Vertex Vf, Vl;
|
TopoDS_Vertex Vf, Vl;
|
||||||
@ -414,6 +417,25 @@ BRepFill_PipeShell::BRepFill_PipeShell(const TopoDS_Wire& Spine)
|
|||||||
mySection.Nullify(); //It is required to relocalize the sections.
|
mySection.Nullify(); //It is required to relocalize the sections.
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
//=======================================================================
|
||||||
|
//function : SetMaxDegree
|
||||||
|
//purpose :
|
||||||
|
//=======================================================================
|
||||||
|
void BRepFill_PipeShell::SetMaxDegree(const Standard_Integer NewMaxDegree)
|
||||||
|
{
|
||||||
|
myMaxDegree = NewMaxDegree;
|
||||||
|
}
|
||||||
|
|
||||||
|
//=======================================================================
|
||||||
|
//function : SetMaxSegments
|
||||||
|
//purpose :
|
||||||
|
//=======================================================================
|
||||||
|
void BRepFill_PipeShell::SetMaxSegments(const Standard_Integer NewMaxSegments)
|
||||||
|
{
|
||||||
|
myMaxSegments = NewMaxSegments;
|
||||||
|
}
|
||||||
|
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
//function : SetForceApproxC1
|
//function : SetForceApproxC1
|
||||||
//purpose : Set the flag that indicates attempt to approximate
|
//purpose : Set the flag that indicates attempt to approximate
|
||||||
@ -742,7 +764,8 @@ void BRepFill_PipeShell::SetForceApproxC1(const Standard_Boolean ForceApproxC1)
|
|||||||
theContinuity = GeomAbs_C0;
|
theContinuity = GeomAbs_C0;
|
||||||
TopTools_MapOfShape Dummy;
|
TopTools_MapOfShape Dummy;
|
||||||
BRepFill_DataMapOfShapeHArray2OfShape Dummy2;
|
BRepFill_DataMapOfShapeHArray2OfShape Dummy2;
|
||||||
MkSw.Build(Dummy, Dummy2, myTransition, theContinuity);
|
MkSw.Build(Dummy, Dummy2, myTransition, theContinuity,
|
||||||
|
GeomFill_Location, myMaxDegree, myMaxSegments);
|
||||||
|
|
||||||
myStatus = myLocation->GetStatus();
|
myStatus = myLocation->GetStatus();
|
||||||
Ok = (MkSw.IsDone() && (myStatus == GeomFill_PipeOk));
|
Ok = (MkSw.IsDone() && (myStatus == GeomFill_PipeOk));
|
||||||
|
@ -221,6 +221,20 @@ is
|
|||||||
-- - boundary tolerance BoundTol
|
-- - boundary tolerance BoundTol
|
||||||
-- - angular tolerance TolAngular.
|
-- - angular tolerance TolAngular.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
-- ============================================
|
||||||
|
-- Methods to set parameters for approximation
|
||||||
|
-- ============================================
|
||||||
|
SetMaxDegree(me : in out;
|
||||||
|
NewMaxDegree : Integer from Standard);
|
||||||
|
---Purpose: Define the maximum V degree of resulting surface
|
||||||
|
|
||||||
|
SetMaxSegments(me : in out;
|
||||||
|
NewMaxSegments : Integer from Standard);
|
||||||
|
---Purpose: Define the maximum number of spans in V-direction
|
||||||
|
-- on resulting surface
|
||||||
|
|
||||||
SetForceApproxC1(me : in out;
|
SetForceApproxC1(me : in out;
|
||||||
ForceApproxC1 : Boolean from Standard);
|
ForceApproxC1 : Boolean from Standard);
|
||||||
---Purpose: Set the flag that indicates attempt to approximate
|
---Purpose: Set the flag that indicates attempt to approximate
|
||||||
|
@ -200,6 +200,24 @@ void BRepOffsetAPI_MakePipeShell::Delete( const TopoDS_Shape& Profile)
|
|||||||
myPipe->SetTolerance(Tol3d, BoundTol, TolAngular);
|
myPipe->SetTolerance(Tol3d, BoundTol, TolAngular);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//=======================================================================
|
||||||
|
//function : SetMaxDegree
|
||||||
|
//purpose :
|
||||||
|
//=======================================================================
|
||||||
|
void BRepOffsetAPI_MakePipeShell::SetMaxDegree(const Standard_Integer NewMaxDegree)
|
||||||
|
{
|
||||||
|
myPipe->SetMaxDegree(NewMaxDegree);
|
||||||
|
}
|
||||||
|
|
||||||
|
//=======================================================================
|
||||||
|
//function : SetMaxSegments
|
||||||
|
//purpose :
|
||||||
|
//=======================================================================
|
||||||
|
void BRepOffsetAPI_MakePipeShell::SetMaxSegments(const Standard_Integer NewMaxSegments)
|
||||||
|
{
|
||||||
|
myPipe->SetMaxSegments(NewMaxSegments);
|
||||||
|
}
|
||||||
|
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
//function : SetForceApproxC1
|
//function : SetForceApproxC1
|
||||||
//purpose : Set the flag that indicates attempt to approximate
|
//purpose : Set the flag that indicates attempt to approximate
|
||||||
|
Loading…
x
Reference in New Issue
Block a user