[vtkusers] Need help getting vtkCanvas as Image via swing or AWT
alan at vuesonix.com
Tue Apr 22 16:40:48 EDT 2003
I'm trying to capture the image output of the vtkCanvas component. I've
// should capture image contents from swing based component
// should capture image contents from awt based component
panel extends Jpanel and contains a vtkCanvas() object.
Although the image size is always correct, the image contents are always
empty. This despite the fact that VTK has displayed a pretty picture
onscreen, Java just doesn't seem to be able to access it at either the
Swing or AWT level.
Can anyone help me capture the output of vtkCanvas to an Image()? Is
there a reason that this can't be done?
Thanks for any insight on this puzzle.
BTW, my workaround has been to capture the component via the Robot() class:
Robot r=new Robot();
This works acceptably, but only if the vtkCanvas is not covered by any
More information about the vtkusers