[vtkusers] problem of writing a JPEG image

Andy Cedilnik andy.cedilnik at kitware.com
Fri Sep 6 16:50:20 EDT 2002


Hello,

You do add some actors do you?
Try:

 w2i Update

before the Write.

			Andy

On Fri, 2002-09-06 at 16:37, Zhan Zhang wrote:
> I met some problem while using the image writing function in VTK. I
> write in TCL running on a Win 2000 platform. Could somebody point out a
> solution for me?
> 
> My TCL script is:
> 
> vtkRenderer ren1
> vtkRenderWindow renWin
>     renWin AddRenderer ren1
> ren1 Render
> 
> vtkWindowToImageFilter w2i
> 	w2i SetInput renWin
> 	
> vtkJPEGWriter writer
> 	writer SetInput [w2i GetOutput]
> 	writer SetFileName "c:\\zhan\\test.jpg"
> 	writer Write
> 
> the error message is attached in this email as "error.gif"





More information about the vtkusers mailing list