]> Creatis software - bbtkGEditor.git/commitdiff
#3251 Bug with segmentation fault with VTK 9.2 ( SupportsOpenGL )
authorEduardo DAVILA <davila@creatis.insa-lyon.fr>
Thu, 28 Jul 2022 09:54:01 +0000 (11:54 +0200)
committerEduardo DAVILA <davila@creatis.insa-lyon.fr>
Thu, 28 Jul 2022 09:54:01 +0000 (11:54 +0200)
appli/bbEditor/bbEditor.cxx
lib/EditorGraphicBBS/bbsWxGUIEditorGraphic/wxVtkSceneManager.cxx

index 4bbc842b47e5b3312c4194f1fbbc0dde9dcb3708..affb5a2462caa6ee0cfe6506646dc9e6757cd8c3 100644 (file)
@@ -129,13 +129,16 @@ bool wxBBEditorApp::OnCmdLineParsed(wxCmdLineParser& parser)
 
 #define GL_MAJOR_VERSION 0x821B
 #define GL_MINOR_VERSION 0x821C
+
 bool wxBBEditorApp::OnInit( )
 {      
-
        vtkRenderWindow *renWin = vtkRenderWindow::New();
+    
+    printf("EED wxBBEditorApp::OnInit >>>>> vtkRenderWindow IsDirect       %d\n", renWin->IsDirect() );
+
+/* EED  2022-07-26 Segmentation fault with VTK9.2 in MacOs
        int supportopengl=renWin->SupportsOpenGL();
        printf("EED wxBBEditorApp::OnInit >>>>> vtkRenderWindow SupportsOpenGL %d\n", supportopengl );
-       printf("EED wxBBEditorApp::OnInit >>>>> vtkRenderWindow IsDirect       %d\n", renWin->IsDirect() );
        renWin->Delete();
        if (supportopengl==0)
        {
@@ -147,7 +150,7 @@ bool wxBBEditorApp::OnInit( )
                wxMessageBox(message);
                exit(0);
        }
-
+*/
        
        vtkOutputWindowbbGEditor *vtkoutputwindowbbgeditor= vtkOutputWindowbbGEditor::New();
        vtkOutputWindow::SetInstance( vtkoutputwindowbbgeditor );
@@ -188,7 +191,6 @@ bool wxBBEditorApp::OnInit( )
                        iegbbs->OpenBBS(input_file[i], input_file[i]); 
                } 
        }
-
        return true;
 }
 
index cf2315f8897c1a43f0e0b7e5644129da15d9a2b7..e839044db26271bb09997f39b5f2cf223433e148 100644 (file)
@@ -74,7 +74,6 @@ namespace bbtk {
        
 wxVtkSceneManager::wxVtkSceneManager(wxGEditorTabPanel *parent, wxVtk3DBaseView *baseView, int idManager,Factory::Pointer bbtkfactory) 
 {
-
        _cbName                                 = "ComplexBoxName";
        _cbPackageName                  = "PackageName";
        _Author                                 = "Author ??";
@@ -111,7 +110,6 @@ wxVtkSceneManager::wxVtkSceneManager(wxGEditorTabPanel *parent, wxVtk3DBaseView
        }
        _idConnectionInCreation = -1;
        _contLastId                             = 0;
-
 }
 
 //=========================================================================
@@ -235,6 +233,7 @@ void wxVtkSceneManager::configureBaseView()
        _fillObjectActor->GetProperty()->SetOpacity(0);
        _aPolygonMapper->Modified();
        _baseView->GetRenderer()->AddActor(_fillObjectActor);
+    
 }
 
 //=========================================================================