Search code examples
paraview

Paraview: How to draw arrow in a point cloud


I would like to know if paraview can manage this scenario:

I have a .txt file composed for this fields: x y z vx vy vz

The first 3 parameters represents the location of the point in the space. The last 3 parameters are the components of the unit vector that represents a direction.

I would like to display the point cloud and for each point display the arrow that indicates indicates a direction using (vx,vy,vz)

I am sorry if it is a basic question, I recently started using paraview and I am a litle bit lost.


Solution

  • ParaView is the perfect tools for this task.

    • Open ParaView
    • Open File -> youFile.txt
    • change the "delimiter" to " "
    • set haveHeaders correctly if you have header or not in your file
    • Apply
    • Filters->TableToPoints
    • X -> x, Y -> y, Z -> z (considering your file has headers)
    • Apply
    • Filters->Calculator -> xv*iHat+yx*jHat+zv*kHat, Apply
    • Filters->Glyph
    • GlyphMode property-> All Point , Apply
    • Done !