Q: How to color vertices/lines of a vtkCellArray?
Mirco Mueller
mirco at pool.informatik.rwth-aachen.de
Wed Sep 22 10:08:54 EDT 1999
Greetings vtk-gurus!
I am trying to get the actors, made of vtkCellArrays and built from
vtkPolyData, colored, the way one usually colors any object in vtk. But
somehow it does not work. I am using the method:
actors->GetProperty()->SetColor( r, g, b );
I tried to call this method before and after I do a:
ren->AddActor( actors );
But it makes not difference. The drawn wireframe stays black. No
matter what I tried. Is there some special case I have to think about
and did not sofar, while working with vtkCellArrays. The code and the
colors I use for coloring are unchanged from a previous version of my
program, where I build the geometry utilising vtkUnstructuredGrid.
I also took a look at the examples from the vtk distribution. There
is a program callced Cube.cxx. There they use vtkScalars to color the
different vertices of the geometry. But even this approach did somehow
not work for me. What general consideration are nesseccary if one wants
to color vtkCellArray objects?
Thanks in advance for your time and kind advice!
Best regards...
Mirco
-----------------------------------------------------------------------------
This is the private VTK discussion list. Please keep messages on-topic.
Check the FAQ at: <http://www.automatrix.com/cgi-bin/vtkfaq>
To UNSUBSCRIBE, send message body containing "unsubscribe vtkusers" to
<majordomo at gsao.med.ge.com>. For help, send message body containing
"info vtkusers" to the same address. Live long and prosper.
-----------------------------------------------------------------------------
More information about the vtkusers
mailing list