[vtkusers] problem with saving image from window

Martin Haidacher maschtei at hotmail.com
Sun Feb 22 13:35:00 EST 2004


hi there.

i have a problem with saving an image from window. here is a portion of my 
code:
...
this->SetSubFrames(k+1);
this->Render();
for (int i = 0; i < k; i++)
{
// cahnge the camera viewing position
this->Render();
}
vtkWindowToImageFilter *w2i = vtkWindowToImageFilter::New();
w2i->SetInput(this);
vtkTIFFWriter *writer = vtkTIFFWriter::New();
writer->SetInput(w2i->GetOutput());
writer->SetFileName(file);
writer->Write();
this->SetSubFrames(0);
...

this code generate a correct output on the screen with all frames, but when 
i'm trying to save an image from the screen only one frame is saved in the 
image. after writing the image there is also just one frame on the screen.
my question: what can i do that i can save the image with all subframes?

thanks everybody who can help me!!!!

greetings, martin.

_________________________________________________________________
Erhöhen Sie Ihren Gänsehaut-Faktor und verschicken Sie virtuelle Küsse! 
http://match.msn.at/match/mt.cfm?pg=channel




More information about the vtkusers mailing list