[Paraview] Display number of cells over time
Jean Favre
jfavre at cscs.ch
Fri Nov 14 09:06:42 EST 2008
Matthias Moeller wrote:
> Hi all,
>
> I've got a time series of unstructured grid files. Besides the
> visualization of a scalar variable I would like to display some
> statistical data. In particular, I would like to display the number of
> elements over time (animation).
I have tried via the Python interface. This works fine for me:
px = servermanager.ProxyManager()
view = servermanager.GetRenderView()
label = servermanager.sources.TextSource()
# here you must get the right data. I assumed "reader" was the source of
your data
label.Text = "# of cells: %d" %
reader.GetDataInformation().GetNumberOfCells()
labelRep = servermanager.filters.TextSourceRepresentation(Input=label)
view.Representations.append(labelRep)
view.StillRender()
getting the right handle on your dataset is left as an exercise, since
it is application dependent
Jean --
Swiss National SuperComputing Center
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.paraview.org/pipermail/paraview/attachments/20081114/14e58a48/attachment.htm>
More information about the ParaView
mailing list