Painting individual voxels of a Structured Grid (vtkPolyData) differently.

Hello everyone,

I have a situation where I have a vtkPolyData created from a structured grid and would like the voxels of this grid painted individually based on some criteria. That is for instance if a voxel is being examined and to be painted and it’s between a given threshold or range I would like it to take on a specified colour. Is there already an existing way to do this if not how can one go about achieving it?

You can assign scalar values to points or cells. These scalar values can be used to set the color, select, delete, hide points or cells using various filters and mappers. See VTK textbook and VTK examples for details.