1 // Created on: 1994-10-21
2 // Created by: Bruno DUMORTIER
3 // Copyright (c) 1994-1999 Matra Datavision
4 // Copyright (c) 1999-2014 OPEN CASCADE SAS
6 // This file is part of Open CASCADE Technology software library.
8 // This library is free software; you can redistribute it and/or modify it under
9 // the terms of the GNU Lesser General Public License version 2.1 as published
10 // by the Free Software Foundation, with special exception defined in the file
11 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
12 // distribution for complete text of the license and disclaimer of any warranty.
14 // Alternatively, this file may be used under the terms of Open CASCADE
15 // commercial license or contractual agreement.
17 #ifndef _BRepFill_TrimSurfaceTool_HeaderFile
18 #define _BRepFill_TrimSurfaceTool_HeaderFile
20 #include <Standard.hxx>
21 #include <Standard_DefineAlloc.hxx>
22 #include <Standard_Handle.hxx>
24 #include <TopoDS_Face.hxx>
25 #include <TopoDS_Edge.hxx>
26 #include <Standard_Boolean.hxx>
27 #include <TColgp_SequenceOfPnt.hxx>
28 #include <Standard_Real.hxx>
29 #include <GeomAbs_Shape.hxx>
31 class Standard_NoSuchObject;
38 //! Compute the Pcurves and the 3d curves resulting
39 //! of the trimming of a face by an extruded surface.
40 class BRepFill_TrimSurfaceTool
47 Standard_EXPORT BRepFill_TrimSurfaceTool(const Handle(Geom2d_Curve)& Bis, const TopoDS_Face& Face1, const TopoDS_Face& Face2, const TopoDS_Edge& Edge1, const TopoDS_Edge& Edge2, const Standard_Boolean Inv1, const Standard_Boolean Inv2);
49 //! Intersect <Bis> with the projection of the edges
50 //! <EdgeOnFi> and returns the intersecting parameters
51 //! on Bis and on the edges
52 //! P.X() : Parameter on Bis
53 //! P.Y() : Parameter on EdgeOnF1
54 //! P.Z() : Parameter on EdgeOnF2
55 //! raises if <Edge> is not a edge of Face1 or Face2.
56 Standard_EXPORT void IntersectWith (const TopoDS_Edge& EdgeOnF1, const TopoDS_Edge& EdgeOnF2, TColgp_SequenceOfPnt& Points) const;
58 //! returns True if the Line (P, DZ) intersect the Faces
59 Standard_EXPORT Standard_Boolean IsOnFace (const gp_Pnt2d& Point) const;
61 //! returns the parameter of the point <Point> on the
62 //! Edge <Edge>, assuming that the point is on the edge.
63 Standard_EXPORT Standard_Real ProjOn (const gp_Pnt2d& Point, const TopoDS_Edge& Edge) const;
65 Standard_EXPORT void Project (const Standard_Real U1, const Standard_Real U2, Handle(Geom_Curve)& Curve, Handle(Geom2d_Curve)& PCurve1, Handle(Geom2d_Curve)& PCurve2, GeomAbs_Shape& myCont) const;
84 Standard_Boolean myInv1;
85 Standard_Boolean myInv2;
86 Handle(Geom2d_Curve) myBis;
97 #endif // _BRepFill_TrimSurfaceTool_HeaderFile