[vtkusers] howto: rectangular grid, circle

David Doria daviddoria+vtk at gmail.com
Mon Feb 8 19:42:09 EST 2010


On Mon, Feb 8, 2010 at 7:38 PM, Nico Schlömer <nico.schloemer at gmail.com>wrote:

> Oh, okay, so if I understand correctly FieldData lets me add random
> data to what I have in the file anyway. Is that right?
>
> Are there other ways of including more data into the XML-style files?
> I was for example imagining something like
>
> <field="myparameter" name="kappa" type="double" value="3.5427" />
>
> for storing parameters connected to the solution of the PDE. I may
> want to store more heavy data about the grid, for example, too.
>
> Well, I guess the problem is that I'm somewhat oblivious as to what
> VT* can and cannot do for me here. E.g., I can't say now if putting
> all relevant parameter data in one (custom format) file, and the
> solution itself in VT* format in another is a sensible thing to do.
>
> Cheers,
> Nico
>

Yep, you got it right. Take for example .vtp (polydata). You can store
1) a list of points
2) data associated with each point (POINTDATA) (as an array the same length
as the point array)
3) a list of cells (0, 1, or 2D - i.e. vertices, lines, or polygons)
4) data associated with each cell (CELLDATA) (as an array the same length as
the cell array)
5) anything you want (including pairs such as kappa=3.5) (FIELDDATA)

The difference from .vtp to .vtu and .vts is simply how the POINTDATA is
stored internally.

Thanks,

David
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20100208/bf7a45b8/attachment.htm>


More information about the vtkusers mailing list