#1059 VTKWriter: creates invalid .vtu files in ascii mode if function value is NaN
Metadata
| Property | Value |
|---|---|
| Reported by | Ansgar Burchardt (burchardt@igpm.rwth-aachen.de) |
| Reported at | Apr 2, 2012 13:51 |
| Type | Bug Report |
| Version | Git (pre2.4) [autotools] |
| Operating System | Unspecified / All |
| Last edited by | Ansgar Burchardt (burchardt@igpm.rwth-aachen.de) |
| Last edited at | Apr 10, 2012 13:11 |
| Closed by | Ansgar Burchardt (burchardt@igpm.rwth-aachen.de) |
| Closed at | Apr 10, 2012 13:11 |
| Closed in version | Unknown |
| Resolution | None |
| Comment |
Description
ParaView cannot load .vtu files written by VTKWriter that contain NaN values and are written in the ascii format with
vtkwriter.pwrite("bug_vtkwriter-broken", "", "", Dune::VTK::ascii);
and gives this error message:
ERROR: In /build/buildd/paraview-3.10.1/VTK/IO/vtkXMLDataReader.cxx, line 510 vtkXMLUnstructuredGridReader (0xc48f080): Cannot read point data array "f" from PointData in piece 0. The data array in the element may be too short.
When using the binary format with
vtkwriter.pwrite("bug_vtkwriter-okay", "", "", Dune::VTK::appendedraw);
ParaView has no problem loading the file.
I have attached a simple program that writes a VTK file with both options for the constant NaN function, but the problem also occurs if only some values are NaN.
Ansgar