Salome HOME
OCC functionality moving out from the widget
[modules/hydro.git] / src / HYDROCurveCreator / CurveCreator_AISCurve.hxx
1 // Copyright (C) 2013  CEA/DEN, EDF R&D, OPEN CASCADE
2 //
3 // This library is free software; you can redistribute it and/or
4 // modify it under the terms of the GNU Lesser General Public
5 // License as published by the Free Software Foundation; either
6 // version 2.1 of the License.
7 //
8 // This library is distributed in the hope that it will be useful,
9 // but WITHOUT ANY WARRANTY; without even the implied warranty of
10 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
11 // Lesser General Public License for more details.
12 //
13 // You should have received a copy of the GNU Lesser General Public
14 // License along with this library; if not, write to the Free Software
15 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
16 //
17 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
18 //
19
20 #ifndef CURVECREATOR_AIS_CURVE_H
21 #define CURVECREATOR_AIS_CURVE_H
22
23 #include "CurveCreator.hxx"
24 #include "CurveCreator_Macro.hxx"
25
26 #include <Standard_DefineHandle.hxx>   
27
28 #include <AIS_Shape.hxx>
29 #include <gp_Pnt.hxx>
30
31 class CurveCreator_Curve;
32
33 DEFINE_STANDARD_HANDLE(CurveCreator_AISCurve, AIS_Shape)
34
35 /**
36  * \class CurveCreator_AISCurve
37  * \brief This class builds an AIS presentation for a curve creator interface
38  */
39 class CurveCreator_AISCurve : public AIS_Shape
40 {
41 public:
42   Standard_EXPORT CurveCreator_AISCurve( CurveCreator_Curve* theCurve );
43
44 protected:
45   /**
46    * Computes the 3D presentation
47    * \param thePM a presentation Manager
48    * \param thePrs a presentation
49    * \theMode a compute mode
50    */
51   Standard_EXPORT virtual void Compute(const Handle(PrsMgr_PresentationManager3d)& thePM,
52                                        const Handle(Prs3d_Presentation)& thePrs,
53                                        const Standard_Integer theMode);
54   
55   /**
56    * Computes the 3D selection
57    * \param theSelection a selection manager
58    * \theMode a selection mode
59    */
60   Standard_EXPORT virtual void ComputeSelection(const Handle(SelectMgr_Selection)& theSelection,
61                                                 const Standard_Integer theMode);
62
63 public:
64   DEFINE_STANDARD_RTTI(CurveCreator_AISCurve)
65
66 protected:
67   void getPoint( const int theSectionId, const int thePointId, gp_Pnt& thePoint );
68
69 protected:
70   CurveCreator_Curve* myCurve;
71 };
72
73 #endif // CURVECREATOR_AIS_CURVE_H