[vtkusers] Help with vtkWindowToImageFilter
Michael Györffy
4mg19 at qlink.queensu.ca
Fri Apr 26 15:51:48 EDT 2002
Hello:
I'm a new user and am trying to save images from generated
PolyData.
Through the excellent help I've received from this forum (Thank you) I'm
trying to take the screenshot and convert it to ImageData using
vtkWindowToImageFilter.
I get an error of:"no matching function for call
to
`vtkRenderWindow::GetOutput ()'".
I don't understand why this doesn't work, but works in examples
such as OffScreenCone.tcl.
Briefly, the layout of my program is:
PolyDataReader
PolyDataMapper
Actor
Renderer
Renderwindow
then I use the following:
vtkWindowToImageFilter *w2if = vtkWindowToImageFilter::New();
w2if->SetInput(renWin->GetOutput());
vtkPNMWriter *pnmwriter=vtkPNMWriter::New();
pnmwriter->SetInput(w2if->GetOutput());
pnmwriter->SetFileName("3Dimagedata.pnm");
pnmwriter->Write();
Any suggestions would be very much appreciated.
Thanks,
Mike
More information about the vtkusers
mailing list