[vtkusers] vtkPolyData, vtkFloatArray and QT

David Doria daviddoria at gmail.com
Thu Feb 23 10:23:14 EST 2012


On Thu, Feb 23, 2012 at 2:29 AM, Hila Hiler <hilahiler at gmail.com> wrote:
> Hi all,
>
> I have a structure which contains:
>
> class myClass
>   {
>      vtkPolyData*    poly;
>      vtkFloatArray*  values;
>    }
>
> while on every location on the poly, a corresponding value is correlated.
>
> I was wondering: how can I present the values on the poly?
> I'm using QT 4.7- maybe there is a way to add a pop up window (or something
> like that) which will show the value while the cursor stands on the poly?
>
> Any information would be very appreciated.
>
> Best,
> Hila

Do you know that you can add the float array directly to the polydata
and then not have a need for this struct at all?

polydata->GetPointData()->AddArray(yourFloatArray);
?

David



More information about the vtkusers mailing list