[vtkusers] mapper question..

Glen.Coates at csiro.au Glen.Coates at csiro.au
Sun Feb 2 17:43:42 EST 2003


On Sat, 1 Feb 2003, K.R.Subramanian wrote:

> 
> I am trying to display images using
> 
> vtkPlaneSource (1x1 size)
> vtkTexture
> 
> and sending this to an actor
> 
> The texture data is in floats, so the docs say it has to be mapped through
> a lookup table - however, I have tried to specify a lookup table(a gray scale lut - with
> just the value component from 0-1) but this doesnt seem to work - I get a
> plain rectangle. Without a lookup  table specification, it uses the red to blue color scale by
> default.
> 
> If I used unsigned chars and dont do any of the lookup table, it works correctly.

I'm not entirely sure if this is the same problem, but when I had problems 
using float texmaps, I found it was because VTK expected the floats to be 
in the range [0..1], so dividing by the pixel maxval (ie 255 for 8bpp, 
65535 for 16bpp etc) makes everything work nicely.

-- 
Cheers,
Glen




More information about the vtkusers mailing list