[vtkusers] How to set the resolution when I save vtkRenderWindow to jpeg?

Helend zheng.bangyou at yahoo.com.cn
Sat Apr 18 09:15:31 EDT 2009


I used these codes to save vtkRenderWindow to jpeg image:
    
    vtkWindowToImageFilter * w2i  = vtkWindowToImageFilter::New();
    w2i->SetInput( renWin );
    vtkJPEGWriter * image  = vtkJPEGWriter::New();
    w2i->Modified();
    image->SetInput( w2i->GetOutput());
    image->SetFileName( "aaa.jpg" );
    image->SetQuality ( 100 );
    image->Write ();

But how to set the resolution of this image?
Thank you very much!
-- 
View this message in context: http://www.nabble.com/How-to-set-the-resolution-when-I-save-vtkRenderWindow-to-jpeg--tp23112834p23112834.html
Sent from the VTK - Users mailing list archive at Nabble.com.




More information about the vtkusers mailing list