[vtkusers] How can i save single renderer as a picture ?

谢 谢 echoxmw at hotmail.com
Wed Dec 3 21:32:09 EST 2003


I want to save a  single render as a picture,when there are several 
renderer in a renderWindow .How can i do?Though  i
know the following code can save renderwindow as a
picture,i couldnt write right code.

vtkWindowToImageFilter
*w2i=vtkWindowToImageFilter::New();
  w2i->SetInput(renWin);
  
  vtkJPEGWriter *writer=vtkJPEGWriter::New();
  writer->SetInput(w2i->GetOutput());
  writer->SetFileName( "/root/document/n.jpg");
  writer->Write();



Thank you very much!

_________________________________________________________________
与联机的朋友进行交流,请使用 MSN Messenger:  http://messenger.msn.com/cn  




More information about the vtkusers mailing list