1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-08-29 14:00:49 +03:00

0026196: Wrong result obtained by projection algorithm.

Improved periodicity handling when trimmed parameters became unclosed or nonperiodic, but underlying geometry closed or periodic.
Added possibility to not perform trim in GeomAdaptor::MakeSurface.

Minor corrections.

Test-case for issue #26196

Correction of comments
This commit is contained in:
aml
2015-09-17 17:09:20 +03:00
committed by bugmaster
parent f41525d378
commit 7afe616f1f
4 changed files with 128 additions and 45 deletions

View File

@@ -101,8 +101,8 @@ Handle(Geom_Curve) GeomAdaptor::MakeCurve (const Adaptor3d_Curve& HC)
//function : MakeSurface
//purpose :
//=======================================================================
Handle(Geom_Surface) GeomAdaptor::MakeSurface(const Adaptor3d_Surface& HS)
Handle(Geom_Surface) GeomAdaptor::MakeSurface(const Adaptor3d_Surface& HS,
const Standard_Boolean theTrimFlag)
{
Handle(Geom_Surface) S;
@@ -148,7 +148,7 @@ Handle(Geom_Surface) GeomAdaptor::MakeSurface(const Adaptor3d_Surface& HS)
case GeomAbs_OffsetSurface:
S = new Geom_OffsetSurface(GeomAdaptor::MakeSurface(HS.BasisSurface()->Surface()),
HS.OffsetValue());
HS.OffsetValue());
break;
case GeomAbs_OtherSurface:
@@ -156,7 +156,7 @@ Handle(Geom_Surface) GeomAdaptor::MakeSurface(const Adaptor3d_Surface& HS)
break;
}
if ( S.IsNull() )
if ( S.IsNull() || !theTrimFlag)
return S;
// trim the surface if necassary.

View File

@@ -48,9 +48,11 @@ public:
//! Curve from Adaptor3d
Standard_EXPORT static Handle(Geom_Curve) MakeCurve (const Adaptor3d_Curve& C);
//! Build a Geom_Surface using the informations from the
//! Surface from Adaptor3d
Standard_EXPORT static Handle(Geom_Surface) MakeSurface (const Adaptor3d_Surface& S);
//! Build a Geom_Surface using the informations from the Surface from Adaptor3d
//! @param theS - Surface adaptor to convert.
//! @param theTrimFlag - True if perform trim surface values by adaptor and false otherwise.
Standard_EXPORT static Handle(Geom_Surface) MakeSurface (const Adaptor3d_Surface& theS,
const Standard_Boolean theTrimFlag = Standard_True);