[vtk-developers] Pay attention, grab a beer: VTK 5.0

Lisa Avila lisa.avila at kitware.com
Mon Nov 3 17:18:19 EST 2003


Hello,


>6. Volume rendering changes (support unstructured volume rendering)
>
>We (with Sandia Natl Lab) are adding volume rendering support for unstructured
>grids. There are some changes to the volume rendering classes (new classes,
>reorganization of old classes). We believe that we can do this without
>impacting the existing class hierarchy.

There will be a (minor?) API change associated with this item: the mapper 
of a volume will change from being a vtkVolumeMapper to a 
vtkAbstractVolumeMapper. A vtkAbstractVolumeMapper returns vtkDataSet * 
from the GetInput() method. vtkVolumeMapper will be a subclass of 
vtkAbstractVolumeMapper, and will return (as usual) a vtkImageData * from 
GetInput(). This means if you had any code that looked like this: 
volume->GetMapper()->GetInput() and you assumed the return type was 
vtkImageData *, then your code would break. Also, the cropping methods are 
not available from the vtkAbstractVolumeMapper level, so you could no 
longer do volume->GetMapper()->CroppingOn() or similar calls.

I believe the impact of this will be minor. For example, none of the VTK 
examples break due to this change. In addition, Kitware has a fairly large 
volume visualization application that requires no modifications to work 
with this change.

Making this change allows us to support subclasses of 
vtkAbstractVolumeMapper that accept vtkUnstructuredGrid as input, while 
using the exact same vtkVolume and vtkVolumeProperty to hold the properties 
of the volume. Users will need to choose the correct type of mapper (based 
on their input data).

Any comments? I plan to begin checking in these changes next week.


Lisa









More information about the vtk-developers mailing list