]> Creatis software - bbtkGEditor.git/blobdiff - lib/EditorGraphicBBS/bbsWxGUIEditorGraphic/wxVtkSceneManager.cxx
Feature #1758
[bbtkGEditor.git] / lib / EditorGraphicBBS / bbsWxGUIEditorGraphic / wxVtkSceneManager.cxx
index b5e431c7c3816a5368d4ec88efde27a08bca5075..dc22523d93d522e21044ec8198bd4d274f258e1b 100644 (file)
@@ -40,6 +40,8 @@
 
 namespace bbtk {
 
+#define POORT_MAX_LINE_SIZE_INTERPRETER 1500
+
 //=========================================================================
        
 // EED 15 oct 2012  wxVtkSceneManager::wxVtkSceneManager(wxGEditorTabPanel *parent, wxVtk3DBaseView *baseView, int idManager,Factory::Pointer bbtkfactory) 
@@ -104,7 +106,6 @@ wxVtkSceneManager::~wxVtkSceneManager()
 
 void wxVtkSceneManager::configureBaseView() 
 {
-       printf("EED wxVtkSceneManager::configureBaseView 0\n");
        vtkInteractorStyleBaseView2D *interactorstylebaseview = vtkInteractorStyleBaseView2D::New();
 
        _baseView->SetInteractorStyleBaseView(interactorstylebaseview);
@@ -192,7 +193,6 @@ void wxVtkSceneManager::configureBaseView()
        _aPolygonMapper->Modified();
 
        _baseView->GetRenderer()->AddActor(_fillObjectActor);
-       printf("EED wxVtkSceneManager::configureBaseView 1\n");
 }
 
 //=========================================================================
@@ -1849,14 +1849,12 @@ void wxVtkSceneManager::getCleanLine(stringstream &inputStream, std::string &lin
 //=========================================================================
 void wxVtkSceneManager::loadDiagram(stringstream &inputStream) 
 {
-       printf("EED wxVtkSceneManager::loadDiagram Start \n");
        int size;
        std::string version = "<void>";
        std::string line = "";
        char delims[] = ":";
        char *result = NULL;
-       int MAX_LINE_SIZE=1500;
-       char poort[MAX_LINE_SIZE];
+       char poort[POORT_MAX_LINE_SIZE_INTERPRETER];
 
        getCleanLine(inputStream, line);
 
@@ -2196,9 +2194,9 @@ void wxVtkSceneManager::loadDiagram(stringstream &inputStream)
                        while (port == "PORT") 
                        {
                                getCleanLine(inputStream, line);//name:value
-                               if (line.length()>=MAX_LINE_SIZE-1)
+                               if (line.length()>=POORT_MAX_LINE_SIZE_INTERPRETER-1)
                                {
-                                       line=line.substr(0, MAX_LINE_SIZE-1);
+                                       line=line.substr(0, POORT_MAX_LINE_SIZE_INTERPRETER-1);
                                }
                                
                                strcpy(poort, line.c_str());
@@ -2294,20 +2292,16 @@ void wxVtkSceneManager::loadDiagram(stringstream &inputStream)
                                        conView->getManualContourView()->AddPoint();
                                }
                        }// version !=1.0
-
                } // for numConns
-
-       } // start
-       
-printf("EED wxVtkSceneManager::loadDiagram End \n");
-
+       } // start      
 }
 //=========================================================================
 
 
 //=========================================================================
 void wxVtkSceneManager::configGComBoxInputOutputPort(bool inputoutput,
-               std::string portName, double xIn, double yIn, double zIn) {
+               std::string portName, double xIn, double yIn, double zIn) 
+{
        int idPort;
        if (inputoutput == true) {
                idPort = createGComplexBoxInputPort(portName);
@@ -2323,7 +2317,8 @@ void wxVtkSceneManager::configGComBoxInputOutputPort(bool inputoutput,
 
 
 //=========================================================================
-GBoxModel* wxVtkSceneManager::findGBox(std::string boxname) {
+GBoxModel* wxVtkSceneManager::findGBox(std::string boxname) 
+{
        int j;
        int idB;
        GBoxModel *bMod;