[vtkusers] rendering a coloured model

Alex Malyushytskyy alexmalvtk at gmail.com
Thu Dec 6 20:19:52 EST 2012


Depending on your situation different approaches might be required.
As for coloring none of them require textures.

You need to decide which data set type you are going to use first.
In case of irregular mesh you would probably want to use vtkPolydata dataset.

in general color can be set per actor, per element or per node

Color can be specified directly or obtained using lookup table and scalar array.
For example direct color (as RGB) per element:
http://www.vtk.org/Wiki/VTK/Examples/Cxx/GeometricObjects/ColoredLines

Alex

On Thu, Dec 6, 2012 at 3:59 PM, Gaurav Gogri <gaurav.gogri83 at gmail.com> wrote:
> Hi,
> I have a triangulated model (vertices with colours and the mesh). I am
> trying to render the 3d model with the colour. Is there a way to do this in
> VTK. I don't have the texture file to map it on to the rendering. Do I have
> to parameterize and create a texture file?
> thanks in advance,
> Gaurav
>
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the VTK FAQ at:
> http://www.vtk.org/Wiki/VTK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.vtk.org/mailman/listinfo/vtkusers
>



More information about the vtkusers mailing list