[vtkusers] deleting frame in vtk java frame

Sebastien Jourdain sebastien.jourdain at kitware.com
Fri May 25 08:21:39 EDT 2012


Sorry I don't get what you mean by delete and what you try to delete.
If that helps, you can look at the vtk/java code in the sample package
of the vtk.jar.

On Thu, May 24, 2012 at 4:41 PM, Elhassan Abdou <hassan.abdou at yahoo.com> wrote:
> Hi all
>
> I am using vtkresliceimageviewer which is inherited from vtkImageViewer2 to
> produce MPR. I succeeded to create the three vtkCanvas and render on them.
> The PROBLEM is there are another three old frames produced from the
> vtkResliceImageViewer and they are empty as the renderer of viewer now is
> directed to vtkcanvas. How i can delete them.
>
> Below is the snippet of adding the viewers to the canvases;
> imagestyle=new vtkInteractorStyleImage();
> iren = sagitallCanvas.GetRenderWindow().GetInteractor();
> iren.SetInteractorStyle(imagestyle);
> sagittalViewer.SetRenderWindow(sagitallCanvas.GetRenderWindow());
> sagittalViewer.SetRenderer(sagitallCanvas.GetRenderer());
> //sagitallCanvas.GetRenderWindow().AddRenderer(sagittalViewer.GetRenderer());
> sagittalViewer.SetupInteractor(iren);
> //sagitallCanvas.GetRenderer().ResetCamera();
> imagestyle=new vtkInteractorStyleImage();
> iren = cronalCanvas.GetRenderWindow().GetInteractor();
> iren.SetInteractorStyle(imagestyle);
> cronalViewer.SetRenderWindow(cronalCanvas.GetRenderWindow());
> cronalViewer.SetRenderer(cronalCanvas.GetRenderer());
> //cronalCanvas.GetRenderWindow().AddRenderer(cronalViewer.GetRenderer());
> cronalViewer.SetupInteractor(iren);
> //cronalCanvas.GetRenderer().ResetCamera();
>
> imagestyle=new vtkInteractorStyleImage();
> iren = axialCanvas.GetRenderWindow().GetInteractor();
> iren.SetInteractorStyle(imagestyle);
> axialViewer.SetRenderWindow(axialCanvas.GetRenderWindow());
> axialViewer.SetRenderer(axialCanvas.GetRenderer());
> axialViewer.SetupInteractor(iren);
>
> Best Regards
>
> El-Hassan Mohamed
> Biomedical engineering
>
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the VTK FAQ at:
> http://www.vtk.org/Wiki/VTK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.vtk.org/mailman/listinfo/vtkusers
>



More information about the vtkusers mailing list