Back to home page

EIC code displayed by LXR

 
 

    


Warning, file /include/opencascade/StdPrs_DeflectionCurve.hxx was not indexed or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).

0001 // Created on: 1992-12-15
0002 // Created by: Jean Louis FRENKEL
0003 // Copyright (c) 1992-1999 Matra Datavision
0004 // Copyright (c) 1999-2014 OPEN CASCADE SAS
0005 //
0006 // This file is part of Open CASCADE Technology software library.
0007 //
0008 // This library is free software; you can redistribute it and/or modify it under
0009 // the terms of the GNU Lesser General Public License version 2.1 as published
0010 // by the Free Software Foundation, with special exception defined in the file
0011 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
0012 // distribution for complete text of the license and disclaimer of any warranty.
0013 //
0014 // Alternatively, this file may be used under the terms of Open CASCADE
0015 // commercial license or contractual agreement.
0016 
0017 #ifndef _StdPrs_DeflectionCurve_HeaderFile
0018 #define _StdPrs_DeflectionCurve_HeaderFile
0019 
0020 #include <Prs3d_Root.hxx>
0021 #include <Prs3d_Drawer.hxx>
0022 #include <gp_Pnt.hxx>
0023 #include <NCollection_Sequence.hxx>
0024 
0025 class Adaptor3d_Curve;
0026 
0027 //! A framework to provide display of any curve with
0028 //! respect to the maximal chordal deviation defined in
0029 //! the Prs3d_Drawer attributes manager.
0030 class StdPrs_DeflectionCurve : public Prs3d_Root
0031 {
0032 public:
0033   DEFINE_STANDARD_ALLOC
0034 
0035   //! adds to the presentation aPresentation the drawing of the curve
0036   //! aCurve with respect to the maximal chordial deviation defined
0037   //! by the drawer aDrawer.
0038   //! The aspect is defined by LineAspect in aDrawer.
0039   //! If drawCurve equals false the curve will not be displayed,
0040   //! it is used if the curve is a part of some shape and PrimitiveArray
0041   //! visualization approach is activated (it is activated by default).
0042   Standard_EXPORT static void Add(const occ::handle<Prs3d_Presentation>& aPresentation,
0043                                   Adaptor3d_Curve&                       aCurve,
0044                                   const occ::handle<Prs3d_Drawer>&       aDrawer,
0045                                   const bool                             drawCurve = true);
0046 
0047   //! adds to the presentation aPresentation the drawing of the curve
0048   //! aCurve with respect to the maximal chordial deviation defined
0049   //! by the drawer aDrawer.
0050   //! The aspect is defined by LineAspect in aDrawer.
0051   //! The drawing will be limited between the points of parameter U1 and U2.
0052   //! If drawCurve equals false the curve will not be displayed,
0053   //! it is used if the curve is a part of some shape and PrimitiveArray
0054   //! visualization approach is activated (it is activated by default).
0055   Standard_EXPORT static void Add(const occ::handle<Prs3d_Presentation>& aPresentation,
0056                                   Adaptor3d_Curve&                       aCurve,
0057                                   const double                           U1,
0058                                   const double                           U2,
0059                                   const occ::handle<Prs3d_Drawer>&       aDrawer,
0060                                   const bool                             drawCurve = true);
0061 
0062   //! adds to the presentation aPresentation the drawing of the curve
0063   //! aCurve with respect to the maximal chordial deviation aDeflection.
0064   //! The aspect is the current aspect
0065   //! If drawCurve equals false the curve will not be displayed,
0066   //! it is used if the curve is a part of some shape and PrimitiveArray
0067   //! visualization approach is activated (it is activated by default).
0068   Standard_EXPORT static void Add(const occ::handle<Prs3d_Presentation>& aPresentation,
0069                                   Adaptor3d_Curve&                       aCurve,
0070                                   const double                           aDeflection,
0071                                   const double                           aLimit,
0072                                   const double                           anAngle   = 0.2,
0073                                   const bool                             drawCurve = true);
0074 
0075   //! adds to the presentation aPresentation the drawing of the curve
0076   //! aCurve with respect to the maximal chordial deviation aDeflection.
0077   //! The aspect is the current aspect
0078   //! Points give a sequence of curve points.
0079   //! If drawCurve equals false the curve will not be displayed,
0080   //! it is used if the curve is a part of some shape and PrimitiveArray
0081   //! visualization approach is activated (it is activated by default).
0082   Standard_EXPORT static void Add(const occ::handle<Prs3d_Presentation>& aPresentation,
0083                                   Adaptor3d_Curve&                       aCurve,
0084                                   const double                           aDeflection,
0085                                   const occ::handle<Prs3d_Drawer>&       aDrawer,
0086                                   NCollection_Sequence<gp_Pnt>&          Points,
0087                                   const bool                             drawCurve = true);
0088 
0089   //! adds to the presentation aPresentation the drawing of the curve
0090   //! aCurve with respect to the maximal chordial deviation aDeflection.
0091   //! The aspect is the current aspect
0092   //! The drawing will be limited between the points of parameter U1 and U2.
0093   //! Points give a sequence of curve points.
0094   //! If drawCurve equals false the curve will not be displayed,
0095   //! it is used if the curve is a part of some shape and PrimitiveArray
0096   //! visualization approach is activated (it is activated by default).
0097   Standard_EXPORT static void Add(const occ::handle<Prs3d_Presentation>& aPresentation,
0098                                   Adaptor3d_Curve&                       aCurve,
0099                                   const double                           U1,
0100                                   const double                           U2,
0101                                   const double                           aDeflection,
0102                                   NCollection_Sequence<gp_Pnt>&          Points,
0103                                   const double                           anAngle   = 0.2,
0104                                   const bool                             drawCurve = true);
0105 
0106   //! returns true if the distance between the point (X,Y,Z) and the
0107   //! drawing of the curve aCurve with respect of the maximal
0108   //! chordial deviation defined by the drawer aDrawer is less then aDistance.
0109   Standard_EXPORT static bool Match(const double                     X,
0110                                     const double                     Y,
0111                                     const double                     Z,
0112                                     const double                     aDistance,
0113                                     const Adaptor3d_Curve&           aCurve,
0114                                     const occ::handle<Prs3d_Drawer>& aDrawer);
0115 
0116   //! returns true if the distance between the point (X,Y,Z) and the
0117   //! drawing of the curve aCurve with respect of the maximal
0118   //! chordial deviation defined by the drawer aDrawer is less
0119   //! then aDistance. The drawing is considered between the points
0120   //! of parameter U1 and U2;
0121   Standard_EXPORT static bool Match(const double                     X,
0122                                     const double                     Y,
0123                                     const double                     Z,
0124                                     const double                     aDistance,
0125                                     const Adaptor3d_Curve&           aCurve,
0126                                     const double                     U1,
0127                                     const double                     U2,
0128                                     const occ::handle<Prs3d_Drawer>& aDrawer);
0129 
0130   //! Returns true if the distance between the point (theX, theY, theZ)
0131   //! and the drawing with respect of the maximal chordial deviation theDeflection is less then
0132   //! theDistance.
0133   Standard_EXPORT static bool Match(const double           theX,
0134                                     const double           theY,
0135                                     const double           theZ,
0136                                     const double           theDistance,
0137                                     const Adaptor3d_Curve& theCurve,
0138                                     const double           theDeflection,
0139                                     const double           theLimit,
0140                                     const double           theAngle);
0141 
0142   //! Returns true if the distance between the point (theX, theY, theZ)
0143   //! and the drawing with respect of the maximal chordial deviation theDeflection is less then
0144   //! theDistance. The drawing is considered between the points of parameter theU1 and theU2.
0145   Standard_EXPORT static bool Match(const double           theX,
0146                                     const double           theY,
0147                                     const double           theZ,
0148                                     const double           theDistance,
0149                                     const Adaptor3d_Curve& theCurve,
0150                                     const double           theU1,
0151                                     const double           theU2,
0152                                     const double           theDeflection,
0153                                     const double           theAngle);
0154 };
0155 
0156 #endif // _StdPrs_DeflectionCurve_HeaderFile