1 // Created on: 2000-06-07
2 // Created by: Galina KULIKOVA
3 // Copyright (c) 2000-2014 OPEN CASCADE SAS
5 // This file is part of Open CASCADE Technology software library.
7 // This library is free software; you can redistribute it and/or modify it under
8 // the terms of the GNU Lesser General Public License version 2.1 as published
9 // by the Free Software Foundation, with special exception defined in the file
10 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
11 // distribution for complete text of the license and disclaimer of any warranty.
13 // Alternatively, this file may be used under the terms of Open CASCADE
14 // commercial license or contractual agreement.
17 #include <Geom2d_Curve.hxx>
18 #include <Geom_Curve.hxx>
19 #include <ShapeUpgrade_FixSmallCurves.hxx>
20 #include <ShapeUpgrade_SplitCurve2d.hxx>
21 #include <ShapeUpgrade_SplitCurve3d.hxx>
22 #include <Standard_Type.hxx>
23 #include <TopoDS_Edge.hxx>
24 #include <TopoDS_Face.hxx>
26 IMPLEMENT_STANDARD_RTTIEXT(ShapeUpgrade_FixSmallCurves,ShapeUpgrade_Tool)
28 //#include <TColGeom_HArray1OfCurve.hxx>
29 //#include <TColStd_HSequenceOfReal.hxx>
30 #//include <TColGeom2d_HArray1OfCurve.hxx>
31 //#include <TColStd_HSequenceOfReal.hxx>
32 #include <ShapeExtend.hxx>
33 #include <TopoDS_Edge.hxx>
34 #include <TopoDS_Face.hxx>
35 #include <Geom_Curve.hxx>
36 #include <Geom2d_Curve.hxx>
37 #include <ShapeUpgrade_SplitCurve3d.hxx>
38 #include <ShapeUpgrade_SplitCurve2d.hxx>
40 //=======================================================================
41 //function : ShapeUpgrade_FixSmallCurves
43 //=======================================================================
45 ShapeUpgrade_FixSmallCurves::ShapeUpgrade_FixSmallCurves()
47 myStatus = ShapeExtend::EncodeStatus ( ShapeExtend_OK );
49 //=======================================================================
52 //=======================================================================
54 void ShapeUpgrade_FixSmallCurves::Init(const TopoDS_Edge& theEdge,const TopoDS_Face& theFace)
61 //=======================================================================
64 //=======================================================================
66 Standard_Boolean ShapeUpgrade_FixSmallCurves::Approx(Handle(Geom_Curve)& /*Curve3d*/,
67 Handle(Geom2d_Curve)& /*Curve2d*/,
68 Handle(Geom2d_Curve)& /*Curve2dR*/,
69 Standard_Real& /*First*/,
70 Standard_Real& /*Last*/)
72 return Standard_False;
75 //=======================================================================
76 //function : SetSplitCurve3dTool
78 //=======================================================================
80 void ShapeUpgrade_FixSmallCurves::SetSplitCurve3dTool(const Handle(ShapeUpgrade_SplitCurve3d)& splitCurve3dTool)
82 mySplitCurve3dTool = splitCurve3dTool;
85 //=======================================================================
86 //function : SetSplitCurve2dTool
88 //=======================================================================
90 void ShapeUpgrade_FixSmallCurves::SetSplitCurve2dTool(const Handle(ShapeUpgrade_SplitCurve2d)& splitCurve2dTool)
92 mySplitCurve2dTool = splitCurve2dTool;
95 //=======================================================================
96 //function : GetSplitCurve3dTool
98 //=======================================================================
100 Handle(ShapeUpgrade_SplitCurve3d) ShapeUpgrade_FixSmallCurves::GetSplitCurve3dTool() const
102 return mySplitCurve3dTool;
105 //=======================================================================
106 //function : GetSplitCurve2dTool
108 //=======================================================================
110 Handle(ShapeUpgrade_SplitCurve2d) ShapeUpgrade_FixSmallCurves::GetSplitCurve2dTool() const
112 return mySplitCurve2dTool;
114 //=======================================================================
117 //=======================================================================
119 Standard_Boolean ShapeUpgrade_FixSmallCurves::Status(const ShapeExtend_Status status) const
121 return ShapeExtend::DecodeStatus ( myStatus, status );