I am trying to add a new Attribute (data array of scalar values) associated to the points of a Delaunay Mesh I have in Paraview. I would like that once it is selected from the GUI, it would show the associated colors and the range of values bar.
I have tried using the methods: .GetPointData().AddArray(array) and other methods available online, which did not work for me.
I would really appreciate if you could help me with this subject.
First I would suggest upgrading to ParaView 5.5 if possible.
It is not clear where you want to add the array ? in a VTK C++ code ? In this case do not forget to set a name to your array.
Thanks for your answer. I was able to finally install the V. 5.5.2.
I have a mesh of type: multiblock dataset, and I want to add the array by using pvpython in Paraview. I have noticed that it is possible to create these arrays by using the programmable filter. I checked the examples here, and also the associated links:
However, I haven’t been able to create the array of scalars I want because the information I have found so far is mainly for meshes which are not multiblock dataset. From the mesh I have I would like to do: