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 <TColgp_SequenceOfPnt.hxx>
27 #include <GeomAbs_Shape.hxx>
33 //! Compute the Pcurves and the 3d curves resulting
34 //! of the trimming of a face by an extruded surface.
35 class BRepFill_TrimSurfaceTool
42 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);
44 //! Intersect <Bis> with the projection of the edges
45 //! <EdgeOnFi> and returns the intersecting parameters
46 //! on Bis and on the edges
47 //! P.X() : Parameter on Bis
48 //! P.Y() : Parameter on EdgeOnF1
49 //! P.Z() : Parameter on EdgeOnF2
50 //! raises if <Edge> is not a edge of Face1 or Face2.
51 Standard_EXPORT void IntersectWith (const TopoDS_Edge& EdgeOnF1, const TopoDS_Edge& EdgeOnF2, TColgp_SequenceOfPnt& Points) const;
53 //! returns True if the Line (P, DZ) intersect the Faces
54 Standard_EXPORT Standard_Boolean IsOnFace (const gp_Pnt2d& Point) const;
56 //! returns the parameter of the point <Point> on the
57 //! Edge <Edge>, assuming that the point is on the edge.
58 Standard_EXPORT Standard_Real ProjOn (const gp_Pnt2d& Point, const TopoDS_Edge& Edge) const;
60 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;
79 Standard_Boolean myInv1;
80 Standard_Boolean myInv2;
81 Handle(Geom2d_Curve) myBis;
92 #endif // _BRepFill_TrimSurfaceTool_HeaderFile