[Ves] How to color polydata with Scalars in VES

Bo Yu yubo1983 at gmail.com
Mon Mar 3 10:48:06 EST 2014


Thank you for your information, Casey, the color do appear, but it seems
that was colored "vertex by vertex", not as I expected: "cell by cell".
I am using bitbucket with my colleagures. I'll try to create a new repo in
github to let you see.

Bo Yu

On Tuesday, March 4, 2014, Casey Goodlett <casey.goodlett at kitware.com>
wrote:

>
> On Mon, Mar 3, 2014 at 12:42 AM, Bo Yu <yubo1983 at gmail.com<javascript:_e(%7B%7D,'cvml','yubo1983 at gmail.com');>
> > wrote:
>
>>
>> pd->GetPointData()->SetScalars(colorTable);//color works like on each
>> vertexes and scalar, color table is an vtkUnsignedCharArray which contains
>> same tuples as vertexes number.
>> //pd->GetCellData()->SetScalars(colorTable);//no color at all, color
>> table is an vtkUnsignedCharArray which contains same tuples as cells number.
>>
>>
>
> Bo,
>
> Once you you run the filter you should not overwrite the scalars as done
> on these lines.
>
> If you already built your colorTable for the vertices you dont need to use
> the CellDataToPointData filter at all just set directly as point data.
>
> Is your problem that colors dont appear or they are not as you intended?
>
> Can you share how you have constructed your colorTable?  Is your code
> anywhere public like github that we could look at?
>
> Thanks
>
> --
> Casey B. Goodlett, Ph.D.
> R&D Engineer
> Kitware, Inc. - North Carolina Office
> http://www.kitware.com
> (919) 969-6990 x310
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/ves/attachments/20140304/891ab75d/attachment-0003.html>


More information about the Ves mailing list