]> Creatis software - bbtkGEditor.git/commitdiff
no message
authordavila <>
Thu, 30 Sep 2010 07:17:09 +0000 (07:17 +0000)
committerdavila <>
Thu, 30 Sep 2010 07:17:09 +0000 (07:17 +0000)
lib/EditorGraphicBBS/bbsVtkGUIEditorGraphic/vtkGBlackBoxView.cxx
lib/EditorGraphicBBS/bbsVtkGUIEditorGraphic/vtkGBoxView.cxx
lib/EditorGraphicBBS/bbsVtkGUIEditorGraphic/vtkGComplexBoxPortView.cxx
lib/EditorGraphicBBS/bbsVtkGUIEditorGraphic/vtkGPortView.cxx
lib/EditorGraphicBBS/bbsWxGUIEditorGraphic/bbtkwxGUIEditorGraphicBBS.cxx
lib/EditorGraphicBBS/bbsWxGUIEditorGraphic/wxVtkSceneManager.cxx
lib/EditorGraphicBBS/bbsWxGUIEditorGraphic/wxVtkSceneManager.h

index 5377d7be778b08ed1fcaafa723dde49fc42caf1b..4dbbbedae0756badc45b963c919ec550c757dc85 100644 (file)
@@ -98,11 +98,18 @@ namespace bbtk
 
                // RaC In the actual version, zInic=zFin=900
 
-               _pts->SetPoint(0, xInic, yInic, zInic );
+//EED          _pts->SetPoint(0, xInic, yInic, zInic );
+//EED          _pts->SetPoint(1, xInic, yFin, zInic );
+//EED          _pts->SetPoint(2, xFin, yFin, zFin );
+//EED          _pts->SetPoint(3, xFin, yInic, zFin );
+
+               _pts->SetPoint(0, -1000, -1000, -1000 );
                _pts->SetPoint(1, xInic, yFin, zInic );
-               _pts->SetPoint(2, xFin, yFin, zFin );
+               _pts->SetPoint(2, 1000, 1000, 1000 );
                _pts->SetPoint(3, xFin, yInic, zFin );
-                               
+               
+               
+               
                lines->InsertNextCell(5);
                lines->InsertCellPoint(0);
                lines->InsertCellPoint(1);
index 89d0252ddb2fb9214c3b8734f0851878e9bccd18..b95f204bf43278e3ef8f5b27ecd1a8dd8921bf1f 100644 (file)
@@ -96,11 +96,18 @@ namespace bbtk
 
                // RaC In the actual version, zInic=zFin=900
 
-               _pts->SetPoint(0, xInic, yInic, zInic );
+//EED          _pts->SetPoint(0, xInic, yInic, zInic );
+//EED          _pts->SetPoint(1, xInic, yFin, zInic );
+//EED          _pts->SetPoint(2, xFin, yFin, zFin );
+//EED          _pts->SetPoint(3, xFin, yInic, zFin );
+
+               _pts->SetPoint(0, -1000, -1000, -1000 );
                _pts->SetPoint(1, xInic, yFin, zInic );
-               _pts->SetPoint(2, xFin, yFin, zFin );
+               _pts->SetPoint(2, 1000, 1000, 1000 );
                _pts->SetPoint(3, xFin, yInic, zFin );
-                               
+               
+               
+               
                lines->InsertNextCell(5);
                lines->InsertCellPoint(0);
                lines->InsertCellPoint(1);
index 3f528c09561010fbaac0a27077caa5a64b358ace..35dc1a8bc592320d9c4c31baf9b6dd59ab671ca6 100644 (file)
@@ -96,11 +96,18 @@ namespace bbtk
 
                // RaC In the actual version, zInic=zFin=900
 
-               _pts->SetPoint(0, xInic, yInic, zInic );
+//EED          _pts->SetPoint(0, xInic, yInic, zInic );
+//EED          _pts->SetPoint(1, xInic, yFin, zInic );
+//EED          _pts->SetPoint(2, xFin, yFin, zFin );
+//EED          _pts->SetPoint(3, xFin, yInic, zFin );
+
+               
+               _pts->SetPoint(0, -1000, -1000, -1000 );
                _pts->SetPoint(1, xInic, yFin, zInic );
-               _pts->SetPoint(2, xFin, yFin, zFin );
+               _pts->SetPoint(2, 1000, 1000, 1000 );
                _pts->SetPoint(3, xFin, yInic, zFin );
-                               
+               
+               
                lines->InsertNextCell(5);
                lines->InsertCellPoint(0);
                lines->InsertCellPoint(1);
index 321a858241e81bd2cc8c05822bf6802661c6b083..40e9478051cc50b9554afee148347d130c6375fb 100644 (file)
@@ -90,10 +90,15 @@ namespace bbtk
 
                double mid = (xInic+xFin)/2;
 
-               _pts->SetPoint(0, xInic, yInic, zInic );
+//EED          _pts->SetPoint(0, xInic, yInic, zInic );
+//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, xFin, yInic, zFin );                          
-                       
+               _pts->SetPoint(2, 1000, 1000, 1000 );                           
+               
+               
                ///************************* FILL *************************
 
                vtkCellArray *strip = vtkCellArray::New();
@@ -126,14 +131,12 @@ namespace bbtk
 
        void vtkGPortView::updateColors()
        {
-               _fillObjectActor->GetProperty()->SetColor(0.5,0.45,0.45);
+               _fillObjectActor->GetProperty()->SetColor(0.45,0.45,0.45);
 
                if(_state==HIGHLIGHTED)
                {
-                       _fillObjectActor->GetProperty()->SetColor(0.8,0.8,0.8);
-               }
-               else
-               {
+                       _fillObjectActor->GetProperty()->SetColor( 0 , 0 , 1 );
+               } else {
                        GPortModel* portm = (GPortModel*)_model;
                        if(portm->isConnected())
                        {
@@ -142,10 +145,8 @@ namespace bbtk
                        else if(portm->isValueSet())
                        {
                                _fillObjectActor->GetProperty()->SetColor(0.55,0.25,0.25);
-                       }
-                       else 
-                       {
-                               _fillObjectActor->GetProperty()->SetColor(0.5,0.45,0.45);
+                       } else {
+                               _fillObjectActor->GetProperty()->SetColor(0.45,0.45,0.45);
                        }
                }
        }
index c9c63b355f3f8165dbddeb0211a16bcba50d15ca..75b6c259d9ba05aa15ee12ee9978bdf46101c223 100644 (file)
@@ -622,10 +622,9 @@ namespace bbtk
                std::string                     packageName = bbDes->GetPackage()->GetName();
 
                this->_tabsMgr->getActualTabPanel()->getSceneManager()->createGBlackBox(50,50,packageName, typeName);
-               
+               this->_tabsMgr->getActualTabPanel()->getSceneManager()->refresh();
                
                printf("EED  wxGUIEditorGraphicBBS::OnClickBtnBox \n");
-               refreshGUIControls();           
        }
        
        //=========================================================================
index 66c468a242fab2830160dfe9299a1c5ce43368b1..60f3cb5b541a09ebbfb1447afa0c41e6f27f8277 100644 (file)
@@ -1449,11 +1449,18 @@ printf("EED  wxVtkSceneManager::createGComplexBoxOutputPort 900-450\n");
 
        //=========================================================================
 
+       
+       void wxVtkSceneManager::refresh()
+       {
+               _baseView->Refresh();
+       }
+       //=========================================================================
+
        void wxVtkSceneManager::refreshScene()
        {
                _baseView->RefreshView();
        }
-
+       
        //=========================================================================
        
        void wxVtkSceneManager::centerView()
index e3bd1b116c6bfc49294aa0d01f145406b10a1e77..61dc0ca132255f30d01060e8bbeb87abf61b385f 100644 (file)
@@ -131,6 +131,7 @@ namespace bbtk
 
                virtual void update(int idController,int command);
 
+               void refresh();
                void refreshScene();
                void displayBlackBoxInfo(std::string packageName, std::string boxName);
                void updateStatusBar(std::string textStatus);
@@ -193,41 +194,40 @@ namespace bbtk
        private:
 
                //wxPanel that uses the manager
-               wxGEditorTabPanel *_parent;
+               wxGEditorTabPanel                                       *_parent;
 
                // Id of the manager, the same of the panel
-               int _idManager;
+               int                                                                     _idManager;
 
                // Boxes number in the scene
-               int _numBoxes;
+               int                                                                     _numBoxes;
 
                // StartDragging
-               bool _startDragging;
+               bool                                                            _startDragging;
 
                // creaMaracasVisu viewer
-               wxVtk3DBaseView *_baseView;
+               wxVtk3DBaseView                                         *_baseView;
 
                // State of the 3D Scene or the virtual world
                int _worldState;
 
                //Map of id - objectController
-               std::map<int,GObjectController*> _controllers;
+               std::map<int,GObjectController*>        _controllers;
 
                //Saves the id's of the selected objects in the controllers map
-               std::vector<int> _selectedObjects;
+               std::vector<int>                                        _selectedObjects;
 
                //Is the diagram in state complex box 
-               bool _isComplexBox;
+               bool                                                            _isComplexBox;
 
-               int _idConnectionInCreation;
+               int                                                                     _idConnectionInCreation;
 
                int _contLastId;
                
-               vtkTextActor3D          *_textActor;
-               vtkPoints                       *_pts;
-               vtkActor                        *_fillObjectActor;
-//EED Borrame          vtkPolyDataMapper       *_fillPolyMapper;
-               vtkDataSetMapper        *_aPolygonMapper;
+               vtkTextActor3D                                          *_textActor;
+               vtkPoints                                                       *_pts;
+               vtkActor                                                        *_fillObjectActor;
+               vtkDataSetMapper                                        *_aPolygonMapper;
 
        protected: