]> Creatis software - bbtkGEditor.git/blobdiff - lib/EditorGraphicBBS/bbsVtkGUIEditorGraphic/vtkGObjectView.h
The actual version updates the status bar with the highlighted object ... Also it...
[bbtkGEditor.git] / lib / EditorGraphicBBS / bbsVtkGUIEditorGraphic / vtkGObjectView.h
index d314081f5e723b1c6457c0eca4ed3bf9d33f66e3..691d2ef3290690c5887ebc58badc5272d261222d 100644 (file)
@@ -46,13 +46,14 @@ Version:   $Revision$
 //Includes same project
 #include "GlobalConstants.h"
 #include "GObjectModel.h"
+#include "Observer.h"
 
 //Includes creaMaracasVisu
-#include <wxVtk3DBaseView.h>
+#include <wxVtkBaseView.h>
+#include <vtkInteractorStyleBaseView.h>
 
 //Includes vtk
 #include <vtkRenderer.h>
-
 #include "vtkConeSource.h"
 #include "vtkPolyDataMapper.h"
 #include "vtkActor.h"
@@ -65,7 +66,7 @@ Version:   $Revision$
 namespace bbtk
 {
 
-       class vtkGObjectView 
+       class vtkGObjectView : public Observer
        {
 
        public: 
@@ -76,27 +77,45 @@ namespace bbtk
                
                //Public methods
                void setModel(GObjectModel *model);
-               void setRenderer(vtkRenderer* renderer);
+               void setBaseView(wxVtkBaseView* baseView);
                void initVtkObjects();
+               
+               virtual bool isPointInside(int X,int Y);
+               virtual void moveObject(int X, int Y);
+
+               virtual void update(int idController,int command);
+               void setStartDragging(bool param);
 
-               virtual void refresh();
+               void setState(int state);
+               int getState();
+               void setRefreshWaiting();
 
        private:
 
                //Private Attributes
+               bool _isStartDragging;
+               double dragDifX;
+               double dragDifY;
+
 
                //Private Methods
                
        protected:
 
                //Protected Attributes
-               vtkRenderer *_renderer;
+               wxVtkBaseView *_baseView;
                GObjectModel *_model;
-               vtkActor *_objectActor;
-
+               vtkActor *_borderObjectActor;
+               vtkActor *_fillObjectActor;
+               vtkPolyDataMapper* _fillPolyMapper;
+               vtkPolyDataMapper* _borderPolyMapper;
+               vtkPoints *_pts;
+               int  _state;
+               
                //Protected Methods
                virtual void createVtkObjects();
                virtual void addVtkActors();
+               virtual void updateColors();
        };