2 #ifndef MANUAL_CONTOUR_H
3 #define MANUAL_CONTOUR_H
8 #include <vtkProperty.h>
10 #include "vtkPoints.h"
11 #include "vtkImageViewer2.h"
12 #include "vtkImageData.h"
15 #include "vtkRenderWindow.h"
17 #include "vtkRenderer.h"
18 #include "vtkRenderWindowInteractor.h" //extremely important with VC++ don't remove !
19 #include "vtkCommand.h"
20 #include "vtkPolyData.h"
21 #include "vtkCellArray.h"
22 #include "vtkPolyDataMapper.h"
23 #include "vtkInteractorObserver.h"
24 #include "vtkInteractorStyleImage.h"
25 #include <vtkKochanekSpline.h>
27 #include <vtkCellPicker.h>
30 #include <vtkCamera.h>
31 #include <vtkPolyLine.h>
32 #include <vtkDataSetMapper.h>
33 #include <vtkUnstructuredGrid.h>
35 #include "wxVTKRenderWindowInteractor.h"
37 #include "InteractorStyleMaracas.h"
43 #include "wxVtkBaseView.h"
47 // ----------------------------------------------------------------------------
48 // ----------------------------------------------------------------------------
49 // ----------------------------------------------------------------------------
56 virtual ~manualPoint();
57 void SetPoint(double x,double y,double z);
58 void SetPointX(double x);
59 void SetPointY(double y);
60 void SetPointZ(double z);
64 virtual manualPoint * Clone();
71 // ----------------------------------------------------------------------------
72 // ----------------------------------------------------------------------------
73 // ----------------------------------------------------------------------------
76 class creaMaracasVisu_EXPORT manualContourModel{
79 virtual ~manualContourModel();
81 virtual manualContourModel * Clone();
82 void CopyAttributesTo( manualContourModel *cloneObject );
83 virtual void Open(FILE *ff); // virtual
84 virtual void Save(FILE *ff); // virtual
85 virtual int GetTypeModel(); // virtual
87 int AddPoint(double x,double y,double z);
88 int InsertPoint(double x,double y,double z);
89 //JSTG 25-04-08 -------------------------------------------------------
90 void InsertPoint_id(int id, double x,double y,double z);
91 //---------------------------------------------------------------------
92 void AddManualPoint( manualPoint* theManualPoint );
94 void DeletePoint(int i);
95 void DeleteAllPoints();
97 void MovePoint(int i,double dx,double dy,double dz);
98 void MoveLstPoints(double dx,double dy,double dz);
99 void MoveAllPoints(double dx,double dy,double dz);
101 int GetIdPoint(double x, double y, double z, int i_range,int type);
102 manualPoint* GetManualPoint(int id);
103 int GetSizeLstPoints();
104 int GetNumberOfPointsSpline();
105 void SetNumberOfPointsSpline(int size);
107 virtual void UpdateSpline();
108 void SetCloseContour(bool closeContour);
109 bool IfCloseContour();
110 //JSTG 25-02-08 -----------------------------------------------------------------
111 //void GetSplinePoint(double t, double &x, double &y, double &z); //Method Original
112 //void GetSplineiPoint(int i, double &x, double &y, double &z); //Method Original
113 //-------------------------------------------------------------------------------
114 double GetPathSize();
115 double GetPathArea();
117 void GetNearestPointAndNormal(double *p, double *rp, double *rn);
119 // JSTG 25-02-08 -----------------------------------------------------------------
120 virtual void GetSpline_i_Point(int i, double *x, double *y, double *z);
121 void GetSpline_t_Point(double t, double *x, double *y, double *z);
122 //--------------------------------------------------------------------------------
124 virtual std::vector<manualContourModel*> ExploseModel( );
128 int _sizePointsContour;
129 std::vector<manualPoint*> _lstPoints;
131 vtkKochanekSpline *_cntSplineX;
132 vtkKochanekSpline *_cntSplineY;
133 vtkKochanekSpline *_cntSplineZ;
135 //JSTG 25-02-08 ----------------------------------------
137 //------------------------------------------------------
142 //--------------------------------------------------------
144 class creaMaracasVisu_EXPORT manualContourModelCircle : public manualContourModel
147 manualContourModelCircle();
148 virtual ~manualContourModelCircle();
149 virtual manualContourModelCircle *Clone();
150 void CopyAttributesTo( manualContourModelCircle *cloneObject);
151 virtual void GetSpline_i_Point(int i, double *x, double *y, double *z);
159 virtual int GetTypeModel();
160 virtual void UpdateSpline();
163 //--------------------------------------------------------
165 class creaMaracasVisu_EXPORT manualContourModelLine : public manualContourModel
168 manualContourModelLine();
169 virtual ~manualContourModelLine();
170 virtual manualContourModelLine *Clone();
171 void CopyAttributesTo( manualContourModelLine *cloneObject);
172 // virtual void GetSpline_i_Point(int i, double *x, double *y, double *z);
174 virtual int GetTypeModel();
177 //--------------------------------------------------------
179 class manualContourModelBullEyeSector : public manualContourModel
182 manualContourModelBullEyeSector();
183 virtual ~manualContourModelBullEyeSector();
184 virtual manualContourModelBullEyeSector *Clone();
185 void CopyAttributesTo( manualContourModelBullEyeSector *cloneObject);
186 void SetSector( double radioA,
190 void GetSector( double *radioA,
194 void SetSize(double ww,double hh);
195 void SetCenter(double cx,double cy);
196 virtual void GetSpline_i_Point(int i, double *x, double *y, double *z);
197 virtual void Save(FILE *ff);
198 virtual void Open(FILE *ff);
210 virtual int GetTypeModel();
214 //--------------------------------------------------------
216 class creaMaracasVisu_EXPORT manualContourModelBullEye : public manualContourModel
219 manualContourModelBullEye();
220 virtual ~manualContourModelBullEye();
221 virtual manualContourModelBullEye *Clone();
222 void CopyAttributesTo( manualContourModelBullEye *cloneObject);
223 virtual void Save(FILE *ff);
224 virtual void Open(FILE *ff);
226 int GetNumberOfPointsSplineSectorBulleEje();
227 void SetNumberOfPointsSplineSectorBulleEje(int);
228 void AddSector( double radioA,
232 void GetSector( int id,
237 manualContourModelBullEyeSector * GetModelSector(int id);
240 int GetSizeOfSectorLst();
241 virtual void UpdateSpline(); // virtual
242 virtual std::vector<manualContourModel*> ExploseModel( );
247 int _numberPointsSlineBySector;
248 std::vector<manualContourModelBullEyeSector *> _lstModelBullEyeSector;
251 std::vector<double> _lstRadioA;
252 std::vector<double> _lstRadioB;
253 std::vector<double> _lstAng;
254 std::vector<double> _lstAngDelta;
257 virtual int GetTypeModel();
262 //--------------------------------------------------------
264 //JSTG 25-02-08 ------------------------------------------
265 class creaMaracasVisu_EXPORT manualContourModelRoi : public manualContourModel
268 manualContourModelRoi();
269 virtual ~manualContourModelRoi();
270 virtual manualContourModelRoi *Clone();
271 void CopyAttributesTo( manualContourModelRoi *cloneObject);
273 virtual int GetTypeModel();
275 //--------------------------------------------------------
278 class manualViewPoint{
283 manualViewPoint(wxVtkBaseView *wxvtkbaseview);
285 void SetSelected(bool selected);
286 void SetPosibleSelected(bool posibleSelected);
288 bool GetPosibleSelected();
289 void DeleteVtkObjects();
290 vtkActor* CreateVtkPointActor();
291 void SetPositionXY(double x, double y, double range, double posZ);
292 vtkActor* GetVtkActor();
293 void UpdateColorActor();
294 void GetSpacing(double spc[3]);
295 void SetSpacing(double spc[3]);
296 void SetWidthLine( double width);
301 bool _posibleSelected;
304 vtkActor *_pointVtkActor;
305 vtkPolyDataMapper *_bboxMapper;
306 wxVtkBaseView *_wxvtkbaseview;
312 // ----------------------------------------------------------------------------
313 // ----------------------------------------------------------------------------
314 // ----------------------------------------------------------------------------
317 class creaMaracasVisu_EXPORT manualViewBaseContour{
319 manualViewBaseContour();
320 virtual ~manualViewBaseContour();
322 virtual int GetType();
323 virtual void Save(FILE *pFile);
324 virtual void Open(FILE *pFile);
327 void AddPoint( manualViewPoint * manualViewPoint );
328 void InsertPoint(int id);
329 void DeleteContour();
330 void DeletePoint(int x, int y,int z);
331 virtual void DeletePoint(int id);
333 virtual void UpdateViewPoint(int id);
334 virtual void UpdateViewPoints();
336 void SetSelected(bool selected);
337 void SetPosibleSelected(bool posibleSelected);
339 bool GetPosibleSelected();
340 void DeleteSelectedPoints();
342 void SetEditable( bool * condition );
346 virtual int GetIdPoint(int x, int y, int z);
348 void SelectPoint(int i,bool select);
349 void SelectLstPoints();
350 void SelectAllPoints(bool select);
351 virtual int SelectPosiblePoint(int x, int y ,int z);
352 bool SelectPosibleContour(int x, int y ,int z);
353 void SelectAllPossibleSelected(bool select);
354 void SetPointSelected(int id,bool select);
355 void SetPointPosibleSelected(int id,bool select);
356 void SetIfViewControlPoints(bool ifShow);
357 bool GetIfViewControlPoints();
359 void UnSelectPoint(int i);
360 void UnSelectLstPoints();
361 void UnSelectAllPoints();
363 void SetModel(manualContourModel *manContModel);
364 void SetWxVtkBaseView(wxVtkBaseView *wxvtkbaseview);
366 virtual void Refresh();
367 int GetNumberOfPoints(); // ???
368 //int GetNumberOfPointsSpline(); //JSTG 25-02-08 In ContourModel is the same method
369 //void SetNumberOfPointsSpline(int size); //JSTG 25-02-08 In ContourModel is the same method
371 void CreateNewContour();
372 double* GetVectorPointsXManualContour();
373 double* GetVectorPointsYManualContour();
374 double* GetVectorPointsZManualContour();
376 virtual bool ifTouchContour(int x,int y, int z);
377 void UpdateColorActor();
379 void SetRange(int range);
384 wxVtkBaseView *GetWxVtkBaseView();
386 virtual void InitMove(int x, int y, int z);
387 virtual void MoveContour(int x, int y, int z);
388 virtual void MoveContour(int horizontalUnits, int verticalUnits );
389 virtual void GetMinMax( double &minX,double &minY, double &minZ, double &maxX, double &maxY, double &maxZ );
390 virtual void TransfromeCoordViewWorld(double &X, double &Y, double &Z, int type=2);
393 virtual void ClearPoint(int id);
395 void SetVisible(bool ok);
396 void SetShowText(bool ok);
398 void GetSpacing(double spc[3]);
399 void SetSpacing(double spc[3]);
401 void SetColorNormalContour(double r, double g, double b);
402 void GetColorNormalContour(double &r, double &g, double &b);
403 void SetColorEditContour(double r, double g, double b);
404 void GetColorEditContour(double &r, double &g, double &b);
405 void SetColorSelectContour(double r, double g, double b);
406 void GetColorSelectContour(double &r, double &g, double &b);
408 //Addinging and removing from visualization specific actors included in the viewer contour
409 void AddCompleteContourActor( bool ifControlPoints = false);
410 void RemoveCompleteContourActor();
411 virtual void AddSplineActor();
412 virtual void RemoveSplineActor();
413 void AddControlPoints();
414 void RemoveControlPoints();
416 void RemoveTextActor();
418 virtual manualViewBaseContour * Clone();
419 void CopyAttributesTo( manualViewBaseContour *cloneObject );
420 virtual void RefreshContour();
421 void SetWidthLine(double width);
422 double GetWidthLine();
424 virtual void ConstructVTKObjects();
429 wxVtkBaseView *_wxvtkbaseview;
432 bool _posibleSelected;
433 bool _viewControlPoints;
437 vtkActor *_contourVtkActor;
438 vtkPolyDataMapper *_bboxMapper;
440 double _coulorEdit_r;
441 double _coulorEdit_g;
442 double _coulorEdit_b;
443 double _coulorNormal_r;
444 double _coulorNormal_g;
445 double _coulorNormal_b;
446 double _coulorSelection_r;
447 double _coulorSelection_g;
448 double _coulorSelection_b;
451 void DeleteVtkObjects();
452 virtual void RefreshText();
459 int _id_viewPoint_for_text;
460 vtkTextActor *_textActor;
461 manualContourModel *_manContModel;
463 // JSTG 25-02-08 --------------------------------------------
464 int _sizePointsContour;
465 //-----------------------------------------------------------
466 std::vector<manualViewPoint*> _lstViewPoints;
472 // ----------------------------------------------------------------------------
473 // ----------------------------------------------------------------------------
474 // ----------------------------------------------------------------------------
477 class creaMaracasVisu_EXPORT manualViewContour: public manualViewBaseContour
481 virtual ~manualViewContour();
482 virtual manualViewContour * Clone();
483 void CopyAttributesTo( manualViewContour *cloneObject );
485 virtual int GetType();
486 virtual void Save(FILE *pFile);
487 virtual void Open(FILE *pFile);
490 virtual void RefreshContour();
491 virtual bool ifTouchContour(int x,int y, int z);
492 virtual void InitMove(int x, int y, int z);
493 virtual void MoveContour(int x, int y, int z);
494 virtual void MoveContour(int horizontalUnits, int verticalUnits );
495 virtual void DeletePoint(int id);
496 virtual void ClearPoint(int id);
497 void SetMesureScale(double mesureScale);
500 std::vector< std::vector<double> > _initialMovingPoints;
501 manualContourModel * _initialConoturModel;
503 virtual void RefreshText();
508 // ----------------------------------------------------------------------------
509 // ----------------------------------------------------------------------------
510 // ----------------------------------------------------------------------------
512 class manualView3VContour: public manualViewContour
515 manualView3VContour(int type);
516 virtual ~manualView3VContour();
517 virtual manualView3VContour * Clone();
518 void CopyAttributesTo( manualView3VContour *cloneObject );
520 virtual void RefreshContour();
521 virtual int GetIdPoint(int x, int y, int z);
522 virtual void UpdateViewPoint(int id);
523 virtual bool ifTouchContour(int x,int y,int z);
529 void FilterCordinateXYZ(double &x,double &y,double &z);
531 // JSTG 25-02-08 -------------------------------------
532 //manualContourModel *_manContModel;
533 //----------------------------------------------------
537 // ----------------------------------------------------------------------------
538 // ----------------------------------------------------------------------------
539 // ----------------------------------------------------------------------------
541 class manualView3DContour: public manualViewContour
544 manualView3DContour();
545 virtual ~manualView3DContour();
546 virtual manualView3DContour * Clone();
547 void CopyAttributesTo( manualView3DContour *cloneObject );
549 virtual void TransfromeCoordViewWorld(double &X, double &Y, double &Z, int type);
550 void SetVtkMPRBaseData(vtkMPRBaseData *vtkmprbasedata);
552 virtual int SelectPosiblePoint ( int x, int y, int z );
553 void SetDimensions(int w, int h, int d);
555 int GetIdPoint2(int x, int y);
558 vtkMPRBaseData *_vtkmprbasedata;
567 // ----------------------------------------------------------------------------
568 // ----------------------------------------------------------------------------
569 // ----------------------------------------------------------------------------
572 class creaMaracasVisu_EXPORT manualViewRoi: public manualViewContour
576 virtual ~manualViewRoi();
578 virtual int GetType();
579 virtual manualViewRoi * Clone();
580 void CopyAttributesTo( manualViewRoi *cloneObject );
582 virtual void RefreshContour();
583 virtual bool ifTouchContour(int x,int y, int z);
584 virtual void InitMove(int x, int y, int z);
585 virtual void MoveContour(int x, int y, int z);
586 void GetMinMax(double &minX,double &minY, double &maxX, double &maxY);
595 // ----------------------------------------------------------------------------
596 // ----------------------------------------------------------------------------
597 // ----------------------------------------------------------------------------
598 class creaMaracasVisu_EXPORT manualViewBullEyeSector: public manualViewContour
601 manualViewBullEyeSector();
602 virtual void RefreshContour();
607 // ----------------------------------------------------------------------------
608 // ----------------------------------------------------------------------------
609 // ----------------------------------------------------------------------------
611 class creaMaracasVisu_EXPORT manualViewBullEye: public manualViewRoi
615 virtual ~manualViewBullEye();
617 virtual int GetType();
618 virtual manualViewBullEye * Clone();
619 void CopyAttributesTo( manualViewBullEye *cloneObject );
621 // void UpdateColorActorBullEye();
622 // void DeleteVtkObjectsBullEye();
623 virtual void RemoveSplineActor();
624 virtual void AddSplineActor();
625 virtual void ConstructVTKObjects();
626 virtual void RefreshContour();
631 std::vector<sectorBullEye* > lstSectorBullEye;
634 std::vector<manualViewBaseContour* > lstSectorBullEye;
639 // ----------------------------------------------------------------------------
640 // ----------------------------------------------------------------------------
641 // ----------------------------------------------------------------------------
644 class creaMaracasVisu_EXPORT manualViewCircle: public manualViewContour
648 virtual ~manualViewCircle();
650 virtual int GetType();
651 virtual manualViewCircle * Clone();
652 void CopyAttributesTo( manualViewCircle *cloneObject );
654 virtual void InitMove(int x, int y, int z);
655 virtual void MoveContour(int x, int y, int z);
656 void GetMinMax(double &minX,double &minY, double &maxX, double &maxY);
664 // ----------------------------------------------------------------------------
665 // ----------------------------------------------------------------------------
666 // ----------------------------------------------------------------------------
669 class creaMaracasVisu_EXPORT manualViewLine: public manualViewContour
673 virtual ~manualViewLine();
675 virtual int GetType();
676 virtual manualViewLine * Clone();
677 void CopyAttributesTo( manualViewLine *cloneObject );
679 virtual void InitMove(int x, int y, int z);
680 virtual void MoveContour(int x, int y, int z);
689 // ----------------------------------------------------------------------------
690 // ----------------------------------------------------------------------------
691 // ----------------------------------------------------------------------------
695 class creaMaracasVisu_EXPORT manualContourBaseControler: public InteractorStyleMaracas
698 manualContourBaseControler();
699 virtual ~manualContourBaseControler();
701 virtual manualContourBaseControler * Clone();
702 void CopyAttributesTo( manualContourBaseControler *cloneObject );
704 virtual bool OnChar();
705 virtual bool OnMouseMove();
706 virtual bool OnLeftButtonDown();
707 virtual bool OnLeftButtonUp();
708 virtual bool OnLeftDClick();
709 virtual bool OnMiddleButtonDown();
710 virtual bool OnMiddleButtonUp();
711 virtual bool OnRightButtonDown();
712 virtual bool OnRightButtonUp();
714 void SetModelView(manualContourModel *manContModel, manualViewBaseContour *manViewBaseCont);
715 manualContourModel * GetManualContourModel();
716 manualViewBaseContour * GetManualViewBaseContour();
719 virtual void MouseClickLeft(int x, int y);
720 virtual void MouseClickRight(int x, int y);
721 virtual void MouseDLeft(int x, int y);
723 virtual void MouseMove(int x, int y);
724 virtual void MouseReleaseLeft(int x, int y);
726 void SetState(int state);
729 void SetEditable( bool condition );
730 bool GetPosibleToMove();
731 void SetPosibleToMove( bool condition );
733 void SetMoving( bool condition );
734 void SetCompleteCreation( bool condition );
735 bool GetIfCompleteCreation ( );
736 void SetKeyBoardMoving( bool condition );
737 bool GetKeyBoardMoving( );
739 void CreateNewManualContour();
740 int GetNumberOfPointsManualContour();
741 int GetNumberOfPointsSplineManualContour();
742 void DeleteContour();
743 virtual void DeleteActualMousePoint(int x, int y );
744 double* GetVectorPointsXManualContour();
745 double* GetVectorPointsYManualContour();
751 virtual void AddPoint(int x, int y, int z);
752 virtual void InsertPoint(int x, int y, int z);
754 virtual void SetPoint( int id ,int x ,int y ,int z);
755 void SetPointX( int id ,int x );
756 void SetPointY( int id ,int y );
757 void SetPointZ( int id ,int z );
759 void Magnet(int x, int y);
760 virtual void ResetContour();
762 virtual void Configure();
766 // virtual manualContourBaseControler * Clone( manualViewBaseContour * cloneView = NULL, manualContourModel * cloneModel = NULL );
770 manualViewBaseContour *_manViewBaseCont;
771 manualContourModel *_manContModel;
779 bool _keyBoardMoving;
786 // ----------------------------------------------------------------------------
787 // ----------------------------------------------------------------------------
788 // ----------------------------------------------------------------------------
791 class creaMaracasVisu_EXPORT manualContourControler: public manualContourBaseControler
794 manualContourControler();
795 virtual ~manualContourControler();
796 virtual manualContourControler * Clone();
797 void CopyAttributesTo( manualContourControler *cloneObject );
799 virtual void MouseClickLeft(int x, int y);
800 virtual void MouseMove(int x, int y);
801 virtual void MouseDLeft( int x, int y);
802 void SetEasyCreation(bool easyCreation);
803 bool GetEasyCreation();
805 virtual void Configure();
813 // ----------------------------------------------------------------------------
814 // ----------------------------------------------------------------------------
815 // ----------------------------------------------------------------------------
820 class creaMaracasVisu_EXPORT manualContour3VControler: public manualContourControler
823 manualContour3VControler(int type);
824 virtual ~manualContour3VControler();
825 virtual manualContour3VControler * Clone();
826 void CopyAttributesTo( manualContour3VControler *cloneObject );
828 virtual bool OnChar();
829 virtual void AddPoint(int x, int y, int z);
830 virtual void InsertPoint(int x, int y, int z);
831 virtual void MouseMove(int x, int y);
832 virtual void ResetContour();
834 void AddManualViewBaseContour( manualViewBaseContour *manViewBaseCont );
836 vtkMPRBaseData *GetVtkMPRBaseData();
837 void SetVtkMPRBaseData (vtkMPRBaseData *vtkmprbasedata );
838 virtual void SetPoint( int id ,int x ,int y ,int z );
840 virtual void DeleteActualMousePoint(int x, int y);
842 void AddPoint_Others();
843 void DeleteActualMousePoint_Others(int id);
844 void MouseMove_Others(int id);
845 void InsertPoint_Others(int id);
846 void OnChar_Others();
847 void ResetContour_Others();
853 vtkMPRBaseData *_vtkmprbasedata;
855 std::vector< manualViewBaseContour* > _lstManualViewBaseContour;
859 // ----------------------------------------------------------------------------
860 // ----------------------------------------------------------------------------
861 // ----------------------------------------------------------------------------
864 class creaMaracasVisu_EXPORT manualContour3DControler: public manualContourControler
867 manualContour3DControler();
868 virtual ~manualContour3DControler();
869 virtual manualContour3DControler * Clone();
870 void CopyAttributesTo( manualContour3DControler *cloneObject );
872 virtual bool OnLeftButtonDown();
873 virtual bool OnChar();
874 virtual void InsertPoint(int x, int y, int z);
875 virtual void MouseClickLeft(int x, int y);
876 void ResetOrientationPlane();
878 vtkMPRBaseData *GetVtkMPRBaseData();
879 void SetVtkMPRBaseData (vtkMPRBaseData *vtkmprbasedata );
884 vtkMPRBaseData *_vtkmprbasedata;
889 // ----------------------------------------------------------------------------
890 // ----------------------------------------------------------------------------
891 // ----------------------------------------------------------------------------
893 class creaMaracasVisu_EXPORT manualContour3V3DControler: public manualContour3DControler
896 manualContour3V3DControler();
897 virtual ~manualContour3V3DControler();
898 virtual manualContour3V3DControler * Clone();
899 void CopyAttributesTo( manualContour3V3DControler *cloneObject );
901 void SetManualContour3VControler(manualContour3VControler *manualcontour3Vcontroler);
902 manualContour3VControler *GetManualContour3VControler();
904 virtual bool OnChar();
905 virtual void AddPoint( int x, int y, int z );
906 virtual void DeleteActualMousePoint(int x, int y);
907 virtual void MouseMove(int x, int y);
908 virtual void InsertPoint(int x, int y, int z);
909 virtual void ResetContour();
914 manualContour3VControler *_manualcontour3Vcontroler;
918 // ----------------------------------------------------------------------------
919 // ----------------------------------------------------------------------------
920 // ----------------------------------------------------------------------------
922 class creaMaracasVisu_EXPORT manualContourPerpPlaneControler: public manualContourControler
925 manualContourPerpPlaneControler();
926 virtual ~manualContourPerpPlaneControler();
927 virtual manualContourPerpPlaneControler * Clone();
928 void CopyAttributesTo( manualContourPerpPlaneControler *cloneObject );
930 void SetVtkMPRBaseData(vtkMPRBaseData *vtkmprbasedata);
931 vtkMPRBaseData *GetVtkMPRBaseData();
933 virtual bool OnChar();
934 virtual bool OnMouseMove();
935 virtual bool OnLeftDClick();
936 virtual void AddPoint( int x, int y, int z );
937 virtual void DeleteActualMousePoint(int x, int y);
938 virtual void MouseMove(int x, int y);
939 virtual void InsertPoint(int x, int y, int z);
940 virtual void ResetContour();
942 void SetManualContour3VControler(manualContour3VControler *manualcontour3Vcontroler);
943 manualContour3VControler *GetManualContour3VControler();
945 virtual void MouseDLeft( int x, int y);
946 void ResetOrientationPlane();
947 void SetVtkInteractorStylePlane2D(InteractorStyleMaracas *vtkinteractorstyleplane2D);
948 InteractorStyleMaracas * GetVtkInteractorStylePlane2D();
952 bool _flagMouseDClick;
953 InteractorStyleMaracas *_vtkinteractorstyleplane2D;
956 vtkMPRBaseData *_vtkmprbasedata;
957 manualContour3VControler *_manualcontour3Vcontroler;
960 // ----------------------------------------------------------------------------
961 // ----------------------------------------------------------------------------
962 // ----------------------------------------------------------------------------
965 class creaMaracasVisu_EXPORT manualRoiControler: public manualContourControler
968 manualRoiControler();
969 virtual ~manualRoiControler();
970 virtual manualRoiControler * Clone();
971 void CopyAttributesTo( manualRoiControler *cloneObject );
973 virtual void MouseClickLeft(int x, int y);
974 virtual void MouseMove(int x, int y );
975 virtual void DeleteActualMousePoint(int x, int y);
976 void InitRoi(int ww, int hh, double porcentage);
977 void SetRoi(int x1, int y1,int x2, int y2);
978 virtual void Configure();
985 // ----------------------------------------------------------------------------
986 // ----------------------------------------------------------------------------
987 // ----------------------------------------------------------------------------
990 class creaMaracasVisu_EXPORT manualCircleControler: public manualContourControler
993 manualCircleControler();
994 virtual ~manualCircleControler();
995 virtual manualCircleControler * Clone();
996 void CopyAttributesTo( manualCircleControler *cloneObject );
998 virtual void MouseClickLeft(int x, int y);
999 virtual void MouseMove(int x, int y );
1000 virtual void DeleteActualMousePoint(int x, int y);
1001 void InitRoi(int ww, int hh, double porcentage);
1002 // void SetRoi(int x1, int y1,int x2, int y2);
1003 virtual void Configure();
1011 // ----------------------------------------------------------------------------
1012 // ----------------------------------------------------------------------------
1013 // ----------------------------------------------------------------------------
1016 class creaMaracasVisu_EXPORT manualLineControler: public manualContourControler
1019 manualLineControler();
1020 virtual ~manualLineControler();
1021 virtual manualLineControler * Clone();
1022 void CopyAttributesTo( manualLineControler *cloneObject );
1024 virtual void MouseClickLeft(int x, int y);
1025 virtual void MouseMove(int x, int y );
1026 virtual void DeleteActualMousePoint(int x, int y);
1027 void InitRoi(int ww, int hh, double porcentage);
1038 #endif // MANUAL_CONTOUR_H