]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Write VTU data as 64-bit values, rather than 32-bit values.
authorWolfgang Bangerth <bangerth@math.tamu.edu>
Thu, 5 Aug 2010 23:43:57 +0000 (23:43 +0000)
committerWolfgang Bangerth <bangerth@math.tamu.edu>
Thu, 5 Aug 2010 23:43:57 +0000 (23:43 +0000)
git-svn-id: https://svn.dealii.org/trunk@21611 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/base/source/data_out_base.cc
deal.II/doc/news/changes.h

index 9f54c0ea2ad912cb8e43e8eee6b633eeef67d0b1..2ae5a1074ad3ad5e0bca5431b8be14cddaac05fc 100644 (file)
@@ -4204,7 +4204,7 @@ DataOutBase::write_vtu (const std::vector<Patch<dim,spacedim> > &patches,
                                   // d=1..3 dimensions
   out << "<Piece NumberOfPoints=\"" << n_nodes <<"\" NumberOfCells=\"" << n_cells << "\" > \n";
   out << "  <Points> \n";
-  out << "    <DataArray type=\"Float32\" NumberOfComponents=\"3\" format=\"ascii\"> \n";
+  out << "    <DataArray type=\"Float64\" NumberOfComponents=\"3\" format=\"ascii\"> \n";
   write_nodes(patches, vtu_out);
   out << "    </DataArray> \n";
   out << "  </Points> \n \n";
@@ -4284,7 +4284,7 @@ DataOutBase::write_vtu (const std::vector<Patch<dim,spacedim> > &patches,
                                       // component names with double
                                       // underscores unless a vector
                                       // name has been specified
-      out << "    <DataArray type=\"Float32\" Name=\"";
+      out << "    <DataArray type=\"Float64\" Name=\"";
       
       if (std_cxx1x::get<2>(vector_data_ranges[n_th_vector]) != "")
                        out << std_cxx1x::get<2>(vector_data_ranges[n_th_vector]);
@@ -4342,13 +4342,13 @@ DataOutBase::write_vtu (const std::vector<Patch<dim,spacedim> > &patches,
   for (unsigned int data_set=0; data_set<n_data_sets; ++data_set)
     if (data_set_written[data_set] == false)
       {
-       out << "    <DataArray type=\"Float32\" Name=\""
+       out << "    <DataArray type=\"Float64\" Name=\""
            << data_names[data_set]
            << "\" format=\"ascii\"> \n";
            
        std::copy (data_vectors[data_set].begin(),
                   data_vectors[data_set].end(),
-                  std::ostream_iterator<double>(out, " "));
+                  std::ostream_iterator<double>(out, "\n"));
        out << '\n';
        out << "    </DataArray> \n";
       }
@@ -4593,6 +4593,7 @@ void DataOutInterface<dim,spacedim>::write_vtu (std::ostream &out) const
 }
 
 
+
 template <int dim, int spacedim>
 void
 DataOutInterface<dim,spacedim>::write_pvtu_record (std::ostream &out,
@@ -4653,7 +4654,7 @@ DataOutInterface<dim,spacedim>::write_pvtu_record (std::ostream &out,
                                       // component names with double
                                       // underscores unless a vector
                                       // name has been specified
-      out << "    <PDataArray type=\"Float32\" Name=\"";
+      out << "    <PDataArray type=\"Float64\" Name=\"";
                
       if (std_cxx1x::get<2>(vector_data_ranges[n_th_vector]) != "")
        out << std_cxx1x::get<2>(vector_data_ranges[n_th_vector]);
@@ -4672,7 +4673,7 @@ DataOutInterface<dim,spacedim>::write_pvtu_record (std::ostream &out,
   for (unsigned int data_set=0; data_set<n_data_sets; ++data_set)
     if (data_set_written[data_set] == false)
       {
-       out << "    <PDataArray type=\"Float32\" Name=\""
+       out << "    <PDataArray type=\"Float64\" Name=\""
            << data_names[data_set]
            << "\" format=\"ascii\"/> \n";
       }  
@@ -4680,7 +4681,7 @@ DataOutInterface<dim,spacedim>::write_pvtu_record (std::ostream &out,
   out << "    </PPointData> \n";
 
   out << "    <PPoints> \n";
-  out << "      <PDataArray type=\"Float32\" NumberOfComponents=\"3\"/> \n";
+  out << "      <PDataArray type=\"Float64\" NumberOfComponents=\"3\"/> \n";
   out << "    </PPoints> \n";
        
   for(unsigned int i=0; i<piece_names.size(); ++i)             
index 92b2f8a3fa65c6fe13e4fdd77bd88e32463f23c2..6f58f79770054b22a7c05e0120c7f707caf312b3 100644 (file)
@@ -164,6 +164,12 @@ inconvenience this causes.
 
 
 <ol>
+  <li><p> Changed: The DataOutBase::write_vtu function now writes data
+  as 64-bit values, rather than 32-bit values.
+  <br>
+  (Scott Miller 2010/08/5)
+  </p>
+
   <li><p> New: MappingQ and MappingQEulerian now support order > 1 also in 
   codimension one. Step-34 has been modified to show how this works.
   <br>

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.