Dune::LevelAmiraMeshWriter< GridType > Class Template Reference
[AmiraMesh]

Provides file writing facilities in the AmiraMesh format for level grids. More...

#include <dune/grid/io/file/amirameshwriter.hh>

Inheritance diagram for Dune::LevelAmiraMeshWriter< GridType >:
Inheritance graph

List of all members.

Public Member Functions

 LevelAmiraMeshWriter ()
 Default constructor.
 LevelAmiraMeshWriter (const GridType &grid, int level)
 Constructor which initializes the AmiraMesh object with a given level grid.
void addGrid (const GridType::LevelGridView &gridView, bool splitAll=false)
 Add a grid view to the file.
void addLevelGrid (const GridType2 &grid, int level, bool splitAll=false)
 Add level grid.
void addLeafGrid (const GridType2 &grid, bool splitAll=false)
 Add leaf grid.
void addCellData (const DataContainer &data, const GridType::LevelGridView &gridView, bool GridSplitUp=false)
 Add cell data.
void addVertexData (const DataContainer &data, const GridType::LevelGridView &gridView, bool GridSplitUp=false)
 Add vertex data.
void write (const std::string &filename, bool ascii=false) const
 Write AmiraMesh object to disk.
void addUniformData (const GridType::LevelGridView &gridView, const array< unsigned int, dim > &n, const DataContainer &data)
 Write data on a uniform grid into an AmiraMesh file.

Static Public Member Functions

static void writeGrid (const GridType &grid, const std::string &filename, int level)
 Write a grid in AmiraMesh format.
template<class VectorType >
static void writeBlockVector (const GridType &grid, const VectorType &f, const std::string &filename, int level, bool GridSplitUp=false)
 Writes an ISTL block vector in AmiraMesh format.

Detailed Description

template<class GridType>
class Dune::LevelAmiraMeshWriter< GridType >

Provides file writing facilities in the AmiraMesh format for level grids.


Constructor & Destructor Documentation

template<class GridType >
Dune::LevelAmiraMeshWriter< GridType >::LevelAmiraMeshWriter (  )  [inline]

Default constructor.

template<class GridType >
Dune::LevelAmiraMeshWriter< GridType >::LevelAmiraMeshWriter ( const GridType &  grid,
int  level 
) [inline]

Constructor which initializes the AmiraMesh object with a given level grid.

References Dune::AmiraMeshWriter< GridType::LevelGridView >::addGrid().


Member Function Documentation

void Dune::AmiraMeshWriter< GridType::LevelGridView >::addCellData ( const DataContainer &  data,
const GridType::LevelGridView &  gridView,
bool  GridSplitUp = false 
) [inherited]

Add cell data.

Parameters:
data An ISTL compliant vector type
gridView Grid view that the data belongs to
GridSplitUp If the grid has been split up into triangles/tetrahedra you have to set GridSplitUp to make the data consistent with the grid
void Dune::AmiraMeshWriter< GridType::LevelGridView >::addGrid ( const GridType::LevelGridView &  gridView,
bool  splitAll = false 
) [inherited]

Add a grid view to the file.

Parameters:
gridView GridView to be written
splitAll If this is set every element of the grid will be split into triangles/tetrahedra. Amira doesn't support 2d quad grids so if this is not set for a quadrilateral grid in 2d the file won't be readable by standard Amira. See the refinement documentation to see which types can be split up yet. If the grid has been split up and contains other types than triangles/tetrahedra you also have to set GridSplitUp when calling the functions "addVertexData" and "writeBlockVector" to make the data consistent with the grid!

Referenced by Dune::LevelAmiraMeshWriter< GridType >::LevelAmiraMeshWriter().

void Dune::AmiraMeshWriter< GridType::LevelGridView >::addLeafGrid ( const GridType2 &  grid,
bool  splitAll = false 
) [inherited]

Add leaf grid.

Parameters:
grid Grid to be written
splitAll If this is set every element of the grid will be split into triangles/tetrahedra. Amira doesn't support 2d quad grids so if this is not set for a quadrilateral grid in 2d the file won't be readable by standard Amira. See the refinement documentation to see which types can be split up yet. If the grid has been split up and contains other types than triangles/tetrahedra you also have to set GridSplitUp when calling the functions "addVertexData" and "writeBlockVector" to make the data consistent with the grid!
void Dune::AmiraMeshWriter< GridType::LevelGridView >::addLevelGrid ( const GridType2 &  grid,
int  level,
bool  splitAll = false 
) [inherited]

Add level grid.

Parameters:
grid Grid to be written
level Level of the level grid that is to be written
splitAll If this is set every element of the grid will be split into triangles/tetrahedra. Amira doesn't support 2d quad grids so if this is not set for a quadrilateral grid in 2d the file won't be readable by standard Amira. See the refinement documentation to see which types can be split up yet. If the grid has been split up and contains other types than triangles/tetrahedra you also have to set GridSplitUp when calling the functions "addVertexData" and "writeBlockVector" to make the data consistent with the grid!
void Dune::AmiraMeshWriter< GridType::LevelGridView >::addUniformData ( const GridType::LevelGridView &  gridView,
const array< unsigned int, dim > &  n,
const DataContainer &  data 
) [inherited]

Write data on a uniform grid into an AmiraMesh file.

void Dune::AmiraMeshWriter< GridType::LevelGridView >::addVertexData ( const DataContainer &  data,
const GridType::LevelGridView &  gridView,
bool  GridSplitUp = false 
) [inherited]

Add vertex data.

Parameters:
data An ISTL compliant vector type
gridView Grid view that the data belongs to
GridSplitUp If the grid has been split up into triangles/tetrahedra you have to set GridSplitUp to make the data consistent with the grid
void Dune::AmiraMeshWriter< GridType::LevelGridView >::write ( const std::string &  filename,
bool  ascii = false 
) const [inherited]

Write AmiraMesh object to disk.

Parameters:
filename Name of the file to write to
ascii Set this if you want an ascii AmiraMesh file
template<class GridType >
template<class VectorType >
static void Dune::LevelAmiraMeshWriter< GridType >::writeBlockVector ( const GridType &  grid,
const VectorType &  f,
const std::string &  filename,
int  level,
bool  GridSplitUp = false 
) [inline, static]

Writes an ISTL block vector in AmiraMesh format.

Parameters:
grid The grid objects that the vector lives on
f The vector to be written. Has to comply with the ISTL conventions
filename The filename
level The level of the grid that the vector lives on
GridSplitUp If the grid has been split up into triangles/tetrahedra you have to set this parameter to make the data consistent with the grid

References Dune::AmiraMeshWriter< GridView >::addCellData(), Dune::AmiraMeshWriter< GridView >::addVertexData(), and Dune::AmiraMeshWriter< GridView >::write().

template<class GridType >
static void Dune::LevelAmiraMeshWriter< GridType >::writeGrid ( const GridType &  grid,
const std::string &  filename,
int  level 
) [inline, static]

Write a grid in AmiraMesh format.

Parameters:
grid The grid objects that is to be written
filename The filename
level The level to be written

References Dune::AmiraMeshWriter< GridView >::write().


The documentation for this class was generated from the following file:

Generated on Fri Apr 29 2011 with Doxygen (ver 1.7.1) [doxygen-log,error-log].