From: Reino Ruusu Date: Tue, 28 Apr 2020 13:21:15 +0000 (+0300) Subject: Disable global VTK warning window X-Git-Tag: v1.43.0~16 X-Git-Url: https://gerrit.simantics.org/r/gitweb?a=commitdiff_plain;h=refs%2Fchanges%2F97%2F4197%2F1;p=simantics%2F3d.git Disable global VTK warning window gitlab #124 Change-Id: I088e823aa6da2c984dc76bb41fecac4289e90225 --- diff --git a/org.simantics.g3d.vtk/src/org/simantics/g3d/vtk/awt/InteractiveVtkPanel.java b/org.simantics.g3d.vtk/src/org/simantics/g3d/vtk/awt/InteractiveVtkPanel.java index 09e88ae6..9ede257e 100644 --- a/org.simantics.g3d.vtk/src/org/simantics/g3d/vtk/awt/InteractiveVtkPanel.java +++ b/org.simantics.g3d.vtk/src/org/simantics/g3d/vtk/awt/InteractiveVtkPanel.java @@ -29,6 +29,7 @@ import vtk.vtkAssemblyPath; import vtk.vtkCellPicker; import vtk.vtkGenericRenderWindowInteractor; import vtk.vtkInteractorStyleTrackballCamera; +import vtk.vtkObject; import vtk.vtkObjectBase; import vtk.vtkPanel; import vtk.vtkPointPicker; @@ -52,6 +53,10 @@ public class InteractiveVtkPanel extends vtkPanel implements VtkView { public InteractiveVtkPanel() { super(); + + // This is actually a static method in C++ + new vtkObject().GlobalWarningDisplayOff(); + iren = new vtkGenericRenderWindowInteractor(); iren.SetRenderWindow(rw); iren.TimerEventResetsTimerOff(); diff --git a/org.simantics.g3d.vtk/src/org/simantics/g3d/vtk/swt/InteractiveVtkComposite.java b/org.simantics.g3d.vtk/src/org/simantics/g3d/vtk/swt/InteractiveVtkComposite.java index 03d0d2fb..aaa20916 100644 --- a/org.simantics.g3d.vtk/src/org/simantics/g3d/vtk/swt/InteractiveVtkComposite.java +++ b/org.simantics.g3d.vtk/src/org/simantics/g3d/vtk/swt/InteractiveVtkComposite.java @@ -18,6 +18,7 @@ import vtk.vtkAreaPicker; import vtk.vtkAssemblyNode; import vtk.vtkAssemblyPath; import vtk.vtkCellPicker; +import vtk.vtkObject; import vtk.vtkObjectBase; import vtk.vtkPointPicker; import vtk.vtkProp; @@ -35,8 +36,9 @@ public class InteractiveVtkComposite extends vtkSwtComponent implements VtkView{ public InteractiveVtkComposite(Composite parentComposite) { super(parentComposite); this.parentComposite = parentComposite; - - // TODO Auto-generated constructor stub + + // This is actually a static method in C++ + new vtkObject().GlobalWarningDisplayOff(); } private boolean updating = false;