I assume you are referring to the Doxygen of the classes located at
http://www.vtk.org/doc/release/5.2/html/. There is some trickery in the
vtkDataArray classes like vtkDoubleArray and vtkIntArray to make them seem like
they inherit directly from vtkDataArray when in fact they really inherit fr
The first argument, sz, is the size of the array. It should equal the number
of components times the number of tuples. The second argument, extSize, can be
ignored. It is the amount of entries that should be added to the array every
time a larger one needs to be allocated. If you make the ar
InsertNextValue will work just fine so long as you are careful about inserting
all the components for each tuple. Most of the time I would recommend using
InsertNextTupleValue instead. However, in either case before filling the array
I recommend calling Allocate first so that the memory will a
You can add more fields by simply adding them to the point data of the output
data object.
output->GetPointData()->AddArray(pressure);
Make sure that you set a name for the arrays (using the SetName method of
vtkDataArray). That is how ParaView/VTK differentiates the fields.
-Ken
On 3/23/0
What you are using is not quite right. First, it sounds like you really want
to create a vtkImageData. This data holds a 1D, 2D, or 3D grid of points with
origin and uniform spacing on each axis. Thus, you would inherit from
vtkImageAlgorithm and cast your output to vtkImageData.
Second, the
Hi, I am writing a custom reader for paraview to read my own data file which
paraview hasn't have.
I have known that the most important method is RequestInformation and
RequestData, and I just want to write a reader that can output the data type
of StructuredPoints with Scalar and some vectors.I ha