]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
Allow output of zone name in tecplot output.
authorhartmann <hartmann@0785d39b-7218-0410-832d-ea1e28bc413d>
Tue, 11 Mar 2008 09:59:37 +0000 (09:59 +0000)
committerhartmann <hartmann@0785d39b-7218-0410-832d-ea1e28bc413d>
Tue, 11 Mar 2008 09:59:37 +0000 (09:59 +0000)
git-svn-id: https://svn.dealii.org/trunk@15884 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/base/include/base/data_out_base.h
deal.II/base/source/data_out_base.cc

index d1078087022cb25061c4dba9cc54174dd0b8a724..1a6d03805ba914e1d08735b1b775546755c9f081 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007 by the deal.II authors
+//    Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -1128,11 +1128,19 @@ class DataOutBase
                                          * produced.
                                          */
         const char* tecplot_binary_file_name;
-      
+
+                                        /**
+                                         * Tecplot allows to assign
+                                         * names to zones. This
+                                         * variable stores this name.
+                                         */
+       const char* zone_name;
+       
                                         /**
                                          * Constructor
                                          **/
-       TecplotFlags (const char* tecplot_binary_file_name = NULL);
+       TecplotFlags (const char* tecplot_binary_file_name = NULL,
+                     const char* zone_name = NULL);
       
                                         /**
                                          * Declare all flags with name
index ca61b475adbf2ae3851f28f5871cfb2a3cb940c4..95d49282eb5075f0a3f8113d6e1117e8acf57f5a 100644 (file)
@@ -1470,9 +1470,11 @@ DataOutBase::GmvFlags::memory_consumption () const
 
 
 DataOutBase::TecplotFlags::
-TecplotFlags (const char* tecplot_binary_file_name)
+TecplotFlags (const char* tecplot_binary_file_name,
+             const char* zone_name)
                 :
-                tecplot_binary_file_name(tecplot_binary_file_name)
+                tecplot_binary_file_name(tecplot_binary_file_name),
+               zone_name(zone_name)
 {}
 
 
@@ -3236,8 +3238,12 @@ void DataOutBase::write_tecplot (const std::vector<Patch<dim,spacedim> > &patche
       out << ", \"" << data_names[data_set] << "\"";
     
     out << '\n';
+
+    out << "zone ";
+    if (flags.zone_name)
+      out << "t=\"" << flags.zone_name << "\" ";
     
-    out << "zone f=feblock, n=" << n_nodes << ", e=" << n_cells
+    out << "f=feblock, n=" << n_nodes << ", e=" << n_cells
        << ", et=" << tecplot_cell_type[dim] << '\n';
   }
 

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.