[vtkusers] Re: How to reconstruct sequence tif slices to 3D graph ?
Valerie R Coffman
valerie.coffman at nist.gov
Wed Apr 18 16:05:46 EDT 2007
Hi,
I am doing something very similar but not with tiffs (for now). You need to use
a vtkVolume instead of vtkActor and you need to use one of the following
mappers: vtkVolumeRayCastMapper, vtkFixedPointVolumeRayCastMapper,
vtkVolumeTextureMapper2D, vtkVolumeTextureMapper3D. Only the
FixedPointVolumeRayCastMapper and VolumeTextureMapper3D can handle images with
more than one component, which your tiffs will most likely be if they are color.
If they are grayscale, you might have only one component and use one of the
other mappers. I've had the most success with the FixedPointVolumeRayCastMapper.
No need to email me the tifs. ;)
Valerie
> How to reconstruct sequence tif slices to 3D graph ?
>
> I open a tif files and save as slice then get 31 tif slices and they are
> about a medical graph.
>
> My code as follow, when I run them I get a black cube only.
>
> I think the mapper and the actor are used uncorrectly.
>
> Thanks a lot !
>
> Regards !
>
> Wang zucheng
>
> *
> *
>
> //Here is my code .
>
> //map to image objects
>
> vtkDataSetMapper aMapper = new vtkDataSetMapper();
>
> aMapper.SetInput(tifReader.GetOutput());
>
> aMapper.ScalarVisibilityOn();
>
>
>
> vtkActor skin = new vtkActor();
>
> skin.SetMapper(aMapper);
>
>
>
More information about the vtkusers
mailing list