]> Creatis software - bbtkGEditor.git/blobdiff - lib/EditorGraphicBBS/bbsVtkGUIEditorGraphic/vtkGPortView.cxx
#3066 bbGEditor Bug New Normal - Refresh vtk objects
[bbtkGEditor.git] / lib / EditorGraphicBBS / bbsVtkGUIEditorGraphic / vtkGPortView.cxx
index c7ee91f0db8960c72b3a0887f706243de869290d..bffe9538080f184af78bb970ec9a7a1d23609cae 100644 (file)
@@ -77,25 +77,19 @@ namespace bbtk {
 
     //=========================================================================
 
-    void vtkGPortView::update( int idController , int command ) {
-
+    void vtkGPortView::update( int idController , int command ) 
+{
         updateColors( ) ;
 
         double xInic , yInic , zInic , xFin , yFin , zFin ;
-
         _model->getInicPoint( xInic , yInic , zInic ) ;
         _model->getFinalPoint( xFin , yFin , zFin ) ;
-
         // RaC In the actual version, zInic=zFin=GPOSITION_Z
-
         double mid = ( xInic + xFin ) / 2 ;
-
         _pts->SetPoint( 0 , xInic , yInic , zInic ) ;
         _pts->SetPoint( 1 , mid , yFin , zInic ) ;
         _pts->SetPoint( 2 , xFin , yInic , zFin ) ;
-
         _fillPolyMapper->Modified( ) ;
-
         //-----------
         setRefreshWaiting( ) ;
     }
@@ -104,8 +98,6 @@ namespace bbtk {
 
     void vtkGPortView::createVtkObjects( ) //virtual
     {
-        _pts = vtkPoints::New( ) ;
-        _pts->SetNumberOfPoints( 3 ) ;
 
         double xInic , yInic , zInic , xFin , yFin , zFin ;
 
@@ -120,9 +112,13 @@ namespace bbtk {
         //EED          _pts->SetPoint(1, mid, yFin, zInic );
         //EED          _pts->SetPoint(2, xFin, yInic, zFin );                          
 
-        _pts->SetPoint( 0 , -1000 , -1000 , -1000 ) ;
-        _pts->SetPoint( 1 , mid , yFin , zInic ) ;
-        _pts->SetPoint( 2 , 1000 , 1000 , 1000 ) ;
+        _pts = vtkPoints::New( ) ;
+        _pts->SetNumberOfPoints( 3 ) ;
+
+//EED 2017-03-02
+//        _pts->SetPoint( 0 , -1000 , -1000 , -1000 ) ;
+//        _pts->SetPoint( 1 , mid , yFin , zInic ) ;
+//        _pts->SetPoint( 2 , 1000 , 1000 , 1000 ) ;
 
 
         ///************************* FILL *************************