[vtkusers] write to BMP

Prabhu Ramachandran prabhu at aero.iitm.ernet.in
Thu Aug 23 13:59:09 EDT 2001


hi,

>>>>> "VMG" == victor marquez garcia <vicmag at hotmail.com> writes:

    VMG> Hello everybody I have a vtkPolyDataMapper render and I want
    VMG> to write that image on a BMP format with the vtkBMPWriter,

Use the vtkWindowToImageFilter and the vtkBMPWriter.  Something like
this:

w2if = vtkWindowToImageFilter()
w2if.SetInput(renwin)
ex = vtkBMPWriter()
ex.SetFileName(file_name)
ex.SetInput(w2if.GetOutput())
ex.Write()

    VMG> how can I do this?  The goal is to make an animation, there
    VMG> is a better way to achieve this?

Read this thread

http://public.kitware.com/pipermail/vtkusers/2001-March/005894.html

in particular read:

http://public.kitware.com/pipermail/vtkusers/2001-March/005907.html

prabhu




More information about the vtkusers mailing list