[vtkusers] 3D coloured scatter plot

Bill Cheatham cheathambill at gmail.com
Thu Jan 5 12:33:56 EST 2012


On 5 January 2012 17:19, David Doria <daviddoria at gmail.com> wrote:

> On Thu, Jan 5, 2012 at 12:14 PM, Bill Cheatham <cheathambill at gmail.com>wrote:
>
>> Hi All,
>>
>> This may be a very obvious question, but I'm having some trouble creating
>> a 3D scatter plot of coloured points.
>>
>> So far, I have been using the directions hinted at in this thread:
>> http://public.kitware.com/pipermail/vtkusers/2004-June/074696.html
>>
>> i.e. I have used the cube.cxx example, and changed setPolys to setVerts.
>> However, this just gives me gray points in 3D space, while I want each
>> point to have its own RGB colour. In addition, it seems like using the
>> points/polygons paradigm is not best suited to what I am trying to achieve;
>> all I really want to do is plot the points themselves, without the added
>> complication of 'unseen' polygons connecting them.
>>
>> Any help or tips would be much appreciated.
>>
>> Thanks,
>>
>> Bill
>>
>
> Is this what you're trying to do?
> http://www.vtk.org/Wiki/VTK/Examples/Cxx/PolyData/ColoredPoints
>
> You may also want to read this:
> http://www.vtk.org/Wiki/VTK/Tutorials/GeometryTopology
>
> David
>


Perfect thanks, this is exactly what I was looking for. For some reason I
couldn't find it (or anything similar) via Google.

Cheers,

Bill
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20120105/8680aba1/attachment.htm>


More information about the vtkusers mailing list