[vtkusers] Incorrect coloring landscape by elevation ?

David Doria daviddoria at gmail.com
Fri Aug 19 11:34:09 EDT 2011


On Fri, Aug 19, 2011 at 11:30 AM, Artem Babayan
<artem.paraview at googlemail.com> wrote:
> Hello,
>
> I and drawing the 3D 'landscape' graph using the data defined on 2D
> structured grid and I would like to color the resulting graphics
> according to elevation. The pipeline looks like this:
>
> vtkImageData->vtkImageDataGeometryFilter->vtkWarpScalar->vtkDataSetMapper
>
> The mapper has a color lookup table. The result (picture attached)
> does not shows the color based on elevation, that is points with the
> same z-coordinates have different colors. Why? It looks like points in
> TRIANGLES which form the surface were colored correctly, by within
> each triangle the color is just interpolated. Is it a correct
> behaviour or am I doing something wrong?
>
> Best wishes
> Artem

Are you trying to color the triangles? or the points? If you color the
points, the colors inside the triangles will indeed be interpolated.

Have you seen these examples?

http://www.vtk.org/Wiki/VTK/Examples/Cxx/Meshes/ElevationFilter
http://www.vtk.org/Wiki/VTK/Examples/Cxx/Meshes/Color_a_mesh_by_height

David



More information about the vtkusers mailing list