mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-04 13:13:25 +03:00
0025124: [Feature request] Removal of continuity checks for offset geometries
Sometimes curve or surface, which is defined as C0, has continuity G1 or above. Offset can be built from these shapes. Therefore, this extended checking was added into SetBasisCurve and SetBasisSurface methods. Main changes in function BRepOffset_Tool::ExtentFace(...): * "return" is added if intersection (in 2D-space) between two edges in a face cannot be found. Basis curve/surface continuity value found (if G1-checking is OK) is set up as BasisContinuity (see myBasisCurveContinuity and myBasisSurfContinuity members which is returned by GetBasisCurveContinuity and GetBasisSurfContinuity() methods). This fact is used in Geom2dAdaptor and in GeomAdaptor classes. Possibility is entered, which allows for basis elements of offset curve/surface to avoid of C0-checking. Test cases were changed according to their new behavior. Test-cases for issue #25124
This commit is contained in:
@@ -179,15 +179,17 @@ GeomAbs_Shape GeomAdaptor_Curve::Continuity() const
|
||||
if (myCurve->IsKind(STANDARD_TYPE(Geom_OffsetCurve)))
|
||||
{
|
||||
const GeomAbs_Shape S =
|
||||
(*((Handle(Geom_OffsetCurve)*)&myCurve))->BasisCurve()->Continuity();
|
||||
(*((Handle(Geom_OffsetCurve)*)&myCurve))->GetBasisCurveContinuity();
|
||||
switch(S)
|
||||
{
|
||||
case GeomAbs_CN: return GeomAbs_CN;
|
||||
case GeomAbs_C3: return GeomAbs_C2;
|
||||
case GeomAbs_C2: return GeomAbs_C1;
|
||||
case GeomAbs_C1: return GeomAbs_C0;
|
||||
case GeomAbs_C1: return GeomAbs_C0;
|
||||
case GeomAbs_G1: return GeomAbs_G1;
|
||||
case GeomAbs_G2: return GeomAbs_G2;
|
||||
default:
|
||||
Standard_NoSuchObject::Raise("GeomAdaptor_Curve::Continuity");
|
||||
Standard_NoSuchObject::Raise("GeomAdaptor_Curve::Continuity");
|
||||
}
|
||||
}
|
||||
else if (myTypeCurve == GeomAbs_OtherCurve) {
|
||||
|
Reference in New Issue
Block a user