[vtkusers] about ray casting pipeline
Yixun Liu
yxliu at fudan.edu.cn
Tue Apr 11 04:15:18 EDT 2006
Hi,
I build a pipeline as:
vtkPiecewiseFunction *tfun = vtkPiecewiseFunction::New();
vtkColorTransferFunction *ctfun = vtkColorTransferFunction::New();
vtkVolumeRayCastCompositeFunction *compositeFunction = vtkVolumeRayCastCompositeFunction::New();
vtkVolumeRayCastMapper *volumeMapper = vtkVolumeRayCastMapper::New();
vtkVolumeProperty *volumeProperty = vtkVolumeProperty::New();
vtkVolume *volume = vtkVolume::New();
volumeMapper->SetInput(threeDImage);//threeDImage point to a vtkImageData
volumeMapper->SetVolumeRayCastFunction(compositeFunction);
volumeProperty->SetColor(ctfun);
volumeProperty->SetScalarOpacity(tfun);
volume->SetMapper(volumeMapper);
volume->SetProperty(volumeProperty);
However, when I change the threeDImage, e.g changing it from 256x256x48 to 512x512x180, the pipeline cannot visualize correctly. It seem that only part of 512x512x180 image can be visualized.
Thanks!
Regards,
Yixun Liu
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20060411/42a5cb41/attachment.htm>
More information about the vtkusers
mailing list