]> Creatis software - creaMaracasVisu.git/blob - lib/maracasVisuLib/src/interface/wxWindows/widgets/ModelShowNPoints.h
#3514 Move selected point with normal
[creaMaracasVisu.git] / lib / maracasVisuLib / src / interface / wxWindows / widgets / ModelShowNPoints.h
1
2 #ifndef __ModelShowNPoints_h_INCLUDED__
3 #define __ModelShowNPoints_h_INCLUDED__
4
5
6 #include <vector>
7 #include <string>
8 #include <vtkImageData.h>
9
10
11 class ModelShowNPoints
12   {
13         public:
14           ModelShowNPoints();
15           ~ModelShowNPoints(); 
16           std::vector<double>                   GetLstPointsX();
17           std::vector<double>                   GetLstPointsY();
18           std::vector<double>                   GetLstPointsZ();
19           void                                                  GetIdPoint(int id, double *x, double *y, double *z);
20           std::string                                   GetIdLabel(int id);
21           std::vector<std::string>              GetLstLabels();
22           void                                                  AddPoint(double x, double y, double z, std::string label);
23           double                                                DistanceSQ(double dX0, double dY0, double dZ0, double dX1, double dY1, double dZ1);
24           int                                                   InsertPoint(double x, double y, double z, std::string label);
25           void                                                  SavePoints(std::string filename);
26       void                              SavePoints_(FILE* ff);
27
28       int                                                       ReadPoints(std::string filename);
29       int                               ReadPoints_(FILE* ff);
30           int                                                   GetNearestPoint();
31
32           int                                                   GetLstPointsSize();
33           void                                                  SetPointId_mReferencePoint(int id);
34           int                                                   IdInsidePoint();
35
36           void                                                  SetPointById(int id, std::vector<double> point);
37
38           void                                                  SetReferencePoint(std::vector<double> ppoint);
39           std::vector<double>                   GetReferencePoint();
40           void                                                  SetImage(vtkImageData *image);
41           std::string                                   CleanSpaces(std::string ss);
42           vtkImageData*                                 GetImage();
43           void                                                  SetRadio(double radio);
44           double                                                GetRadio();
45           int                                                   RenamePoint(std::string label);
46           void                                                  ErasePoint(int id);
47           void                                                  SetFirstTime(bool value);
48           bool                                                  GetFirstTime();
49       void                              InversLstPoints();
50       int                                                       GetCurrentPoint();
51       
52         private:
53           std::vector<double>           lstPointsX;
54           std::vector<double>           lstPointsY;
55           std::vector<double>           lstPointsZ;
56           std::vector<std::string>      lstLabels;
57           std::vector<double>                   mReferencePoint;
58           double                                mradio;
59           vtkImageData                          *mimage;
60           bool                                                  firsttime;
61           int                                                   currentPoint;
62
63   };
64
65
66 #endif // __ModelShowNPoints_h_INCLUDED__
67
68