[Paraview] How to add vector/scalar field as attributes to a vtkPointSet (vtkPolyData, ...)?

Andy Bauer andy.bauer at kitware.com
Tue Oct 12 13:13:16 EDT 2010


For the velocity array you'll need to set the number of components.  You
probably want to set the number of components to 3 for both 2D and 3D so
that ParaView can manipulate the vector quantities (for 2D just set the last
component to 0).

Using the glyph filter will give you arrows for showing the velocity
magnitude and direction.

On Tue, Oct 12, 2010 at 12:08 PM, R M <mlokida at yahoo.fr> wrote:

> Hi,
>
> Like the title say, I would to like to add some attributes to a vtkPointSet
> (vtkPolyData and vtkUnstructuredGrid).
> The attributes are vector(2D, 3D,...) field or scalar field.
>
> For a scalar Field, If I want to add an attribute to the cells , I do:
> output->GetCellData()->AddArray( data) and
> output->GetPointData()->AddArray(donnees);  for the points
> For the moment it is ok, because I can select them in Paraview.
>
> But now, I have a 2D (or 3D) vector field (velocity) and I would to add the
> velocity field for the points or the cells.  How can I do that ?
> Moreover, if I want to show somme arrow (to show the direction of the
> vectors) should I use the glyph filter ?
>
> Thank you.
>
>
>
> _______________________________________________
> 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 ParaView Wiki at:
> http://paraview.org/Wiki/ParaView
>
> Follow this link to subscribe/unsubscribe:
> http://www.paraview.org/mailman/listinfo/paraview
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.paraview.org/pipermail/paraview/attachments/20101012/d0e3ef89/attachment.htm>


More information about the ParaView mailing list