[Dune] [vtk] beginPointData() in vtuwriter.hh

Oleh Krehel krehel at am.uni-erlangen.de
Mon Mar 28 17:22:14 CEST 2011


Dear DUNE developers,

When I VTKWriter::addVertexData() a vector(7 components for example), and
open with ParaView,
I get the following:

Warning: In
/home/kitware/Kitware/ParaView-3.10/source/VTK/Filtering/vtkDataSetAttributes.cxx,
line 1052

vtkPointData (0x32b3830): Can not set attribute Vectors. Incorrect number of
components.
The problem is apparently that Paraview wants only vectors with 3
components.
I have found that this problem can be corrected by removing the underlined
segment:

<VTKFile type="UnstructuredGrid" version="0.1" byte_order="LittleEndian">
  <UnstructuredGrid>
    <Piece NumberOfCells="4" NumberOfPoints="9">
      <PointData* Vectors="u"*>
        <DataArray type="Float32" Name="u" NumberOfComponents="7"
format="ascii">
        ....

This can be done by simple correction in beginPointData() in vtuwriter.hh:.
I attach the vtk file so you can see the problem.

best regards,
Oleh Krehel
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.dune-project.org/pipermail/dune/attachments/20110328/8f579c0e/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Coagulation_Q1Q1-00000.vtu
Type: application/octet-stream
Size: 1269 bytes
Desc: not available
URL: <https://lists.dune-project.org/pipermail/dune/attachments/20110328/8f579c0e/attachment.obj>


More information about the Dune mailing list