[vtkusers] alpha transparency: image to texture
David Gobbi
dgobbi at irus.rri.on.ca
Thu Apr 19 09:46:26 EDT 2001
Hi Jan,
You end up with a 6-component image, because vtkWindowToImageFilter
always extracts an RGB bitmap. Take a look at vtkCompositeFilter.
- David
On Thu, 19 Apr 2001, Jan Vittrup Hansen wrote:
> Hi,
>
> I need to map some monochrome texturemaps with the output from a rendering
> of a sphere. This I've managed to do by straight application of the
> vtkWindowToImageFilter. Only the background is included in the texturemap,
> where I'd much rather have transparency. Naively I tried the following approach
> only to get a core dump when I try to render using the map - am I missing
> something? (btw: I try to create a monochrome image with alpha transparency -
> i.e. 2 bytes per pixel)
>
> Regards, Jan...
> ...
> filter = vtkWindowToImageFilter()
> filter.SetInput(renderWindow)
>
> image = vtkImageAppendComponents()
> image.SetInput1(filter.GetOutput())
> image.SetInput2(filter.GetOutput())
>
> return image.GetOutput()
> ...
>
> _______________________________________________
> This is the private VTK discussion list.
> Please keep messages on-topic. Check the FAQ at: <http://public.kitware.com/cgi-bin/vtkfaq>
> Follow this link to subscribe/unsubscribe:
> http://public.kitware.com/mailman/listinfo/vtkusers
>
More information about the vtkusers
mailing list