X-Git-Url: https://gerrit.simantics.org/r/gitweb?a=blobdiff_plain;f=org.simantics.g3d.vtk%2Fsrc%2Forg%2Fsimantics%2Fg3d%2Fvtk%2Fswt%2FInteractiveVtkComposite.java;h=3963f16507923e419b78b430bee59c160217b561;hb=2023a4a11c0be1b1d8a51800b068c0ae339bbab7;hp=b8f9ff0c459ded51c4e38679d8c5d595cd1e0b21;hpb=53d55c24c779745f188bdb18d32f71d20acb61b2;p=simantics%2F3d.git 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 b8f9ff0c..3963f165 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 @@ -1,17 +1,12 @@ package org.simantics.g3d.vtk.swt; import java.util.ArrayList; -import java.util.Arrays; import java.util.List; -import javax.vecmath.Vector3d; - import org.eclipse.swt.widgets.Composite; -import org.simantics.g3d.math.Ray; import org.simantics.g3d.scenegraph.RenderListener; import org.simantics.g3d.vtk.action.vtkAction; import org.simantics.g3d.vtk.common.VtkView; -import org.simantics.g3d.vtk.utils.vtkUtil; import org.simantics.utils.threads.IThreadWorkQueue; import org.simantics.utils.threads.SWTThread; import org.simantics.utils.threads.ThreadUtils; @@ -23,7 +18,7 @@ import vtk.vtkAreaPicker; import vtk.vtkAssemblyNode; import vtk.vtkAssemblyPath; import vtk.vtkCellPicker; -import vtk.vtkCoordinate; +import vtk.vtkObject; import vtk.vtkObjectBase; import vtk.vtkPointPicker; import vtk.vtkProp; @@ -41,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; @@ -183,10 +179,6 @@ public class InteractiveVtkComposite extends vtkSwtComponent implements VtkView{ public void lock() { getVTKLock().lock(); - if (getComponent().getContext() != null && !getComponent().getContext().isCurrent()) { - int ret = getComponent().getContext().makeCurrent(); -// System.out.println("Make current2 " + ret); - } } public void unlock() {