From: heister Date: Tue, 3 Jan 2012 16:56:10 +0000 (+0000) Subject: fix .vtu output when we have no zlib X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ee4aca6b9a29af1f4f4e29e145dd74302fdca0cd;p=dealii-svn.git fix .vtu output when we have no zlib git-svn-id: https://svn.dealii.org/trunk@24873 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/deal.II/doc/news/changes.h b/deal.II/doc/news/changes.h index 03c1b7825d..5cb71117c5 100644 --- a/deal.II/doc/news/changes.h +++ b/deal.II/doc/news/changes.h @@ -74,6 +74,10 @@ enabled due to a missing include file in file
    +
  1. Fixed: writing vtu output when no ZLIB is found. +
    +(Timo Heister, 2012/01/03) +
  2. Improved: PETScWrappers::SolverXXX class was restricted to using default solver options for the KSP only. It is now possible to override those by using PETSc command-line options diff --git a/deal.II/source/base/data_out_base.cc b/deal.II/source/base/data_out_base.cc index a1f08292b8..70290c412f 100644 --- a/deal.II/source/base/data_out_base.cc +++ b/deal.II/source/base/data_out_base.cc @@ -4877,8 +4877,17 @@ DataOutBase::write_vtu (const std::vector > &patches, << ascii_or_binary << "\">\n"; { + // uint8_t might be a typedef to unsigned + // char which is then not printed as + // ascii integers +#ifdef HAVE_LIBZ + std::vector cell_types (n_cells, + static_cast(vtk_cell_type[dim])); +#else + std::vector cell_types (n_cells, + vtk_cell_type[dim]); +#endif // this should compress well :-) - std::vector cell_types (n_cells, vtk_cell_type[dim]); vtu_out << cell_types; } out << "\n";