0030901: Visualization - OSD_MemInfo moving memory computation out of the constructor
[occt.git] / samples / mfc / standard / Common / ISession2D / ISession2D_Shape.h
CommitLineData
7fd59977 1#ifndef _ISession2D_Shape_HeaderFile
2#define _ISession2D_Shape_HeaderFile
3
b3837d74 4#include "AIS_InteractiveObject.hxx"
5#include "Graphic3d_ArrayOfPolylines.hxx"
7fd59977 6#include <HLRAlgo_Projector.hxx>
7#include <HLRBRep_Algo.hxx>
8#include <HLRBRep_PolyAlgo.hxx>
b3837d74 9#include <NCollection_List.hxx>
10#include "SelectMgr_SelectableObject.hxx"
11#include <Standard_Macro.hxx>
12#include <Standard_DefineHandle.hxx>
13#include "TopoDS_Shape.hxx"
9e3ca93a 14class ISession2D_Shape;
7fd59977 15DEFINE_STANDARD_HANDLE(ISession2D_Shape,AIS_InteractiveObject)
7fd59977 16
b3837d74 17class ISession2D_Shape : public AIS_InteractiveObject
18{
7fd59977 19public:
b3837d74 20 Standard_EXPORT ISession2D_Shape ();
7fd59977 21
b3837d74 22 // Adds shape to the list of topological shapes
23 void Standard_EXPORT Add (const TopoDS_Shape& aShape);
7fd59977 24
b3837d74 25 // Removes shape from the list of shapes.
26 // It is used in case of shapes erasing.
27 void Standard_EXPORT Remove (const TopoDS_Shape& theShape);
28 // Returns myProjector
29 HLRAlgo_Projector& Projector() { return myProjector;};
5c573e69 30
b3837d74 31 Standard_EXPORT void SetProjector (HLRAlgo_Projector& aProjector);
7fd59977 32
7fd59977 33
b3837d74 34 Standard_Integer& NbIsos() { return myNbIsos;};
7fd59977 35
b3837d74 36 Standard_EXPORT void SetNbIsos (Standard_Integer& aNbIsos);
7fd59977 37
b3837d74 38 Standard_Boolean AcceptShapeDecomposition() {return Standard_True;}
7fd59977 39
b3837d74 40 virtual Standard_Boolean AcceptSelectionMode (const Standard_Integer /*aMode*/) const
41 { return Standard_True; }
7fd59977 42
b3837d74 43public:
92efcf78 44 DEFINE_STANDARD_RTTIEXT(ISession2D_Shape,AIS_InteractiveObject)
7fd59977 45
b3837d74 46private:
47 void BuildAlgo();
48 void BuildPolyAlgo();
7fd59977 49
b3837d74 50 void DrawCompound (const Handle(Prs3d_Presentation)& thePresentation,
51 const TopoDS_Shape& theCompound,
52 const Handle(Prs3d_LineAspect) theAspect);
7fd59977 53
b3837d74 54 Standard_EXPORT virtual void Compute (const Handle(PrsMgr_PresentationManager3d)& thePresentationManager,
55 const Handle(Prs3d_Presentation)& thePresentation,
56 const Standard_Integer theMode = 0);
7fd59977 57
b3837d74 58 virtual void ComputeSelection (const Handle(SelectMgr_Selection)& aSelection,
59 const Standard_Integer aMode);
7fd59977 60
b3837d74 61private:
62
63 Standard_Integer myNbIsos;
64 NCollection_List<TopoDS_Shape> myListOfShape;
65 HLRAlgo_Projector myProjector;
66 Handle(HLRBRep_Algo) myAlgo;
67 Handle(HLRBRep_PolyAlgo) myPolyAlgo;
68};
7fd59977 69// other inCurve functions and methods (like "C++: function call" methods)
70//
71
72
73
74#endif