|
| VtkWriterInterface (GridView const &gridView, Vtk::FormatTypes format=Vtk::FormatTypes::BINARY, Vtk::DataTypes datatype=Vtk::DataTypes::FLOAT32, Vtk::DataTypes headertype=Vtk::DataTypes::UINT32) |
| Constructor, passes the gridView to the DataCollector.
|
|
| VtkWriterInterface (DataCollector &dataCollector, Vtk::FormatTypes format=Vtk::FormatTypes::BINARY, Vtk::DataTypes datatype=Vtk::DataTypes::FLOAT32, Vtk::DataTypes headertype=Vtk::DataTypes::UINT32) |
| Constructor, wraps the passed DataCollector in a non-destroying shared_ptr.
|
|
| VtkWriterInterface (std::shared_ptr< DataCollector > dataCollector, Vtk::FormatTypes format=Vtk::FormatTypes::BINARY, Vtk::DataTypes datatype=Vtk::DataTypes::FLOAT32, Vtk::DataTypes headertype=Vtk::DataTypes::UINT32) |
| Constructor, stores the passed DataCollector.
|
|
virtual std::string | write (std::string const &fn, std::optional< std::string > dir={}) const override |
| Write the attached data to the file.
|
|
template<class Function , class... Args> |
VtkWriterInterface & | addPointData (Function &&fct, Args &&... args) |
| Attach point data to the writer.
|
|
template<class Function , class... Args> |
VtkWriterInterface & | addCellData (Function &&fct, Args &&... args) |
| Attach cell data to the writer.
|
|
void | setFormat (Vtk::FormatTypes format) |
|
void | setDatatype (Vtk::DataTypes datatype) |
| Sets the global datatype used for coordinates and other global float values.
|
|
void | setHeadertype (Vtk::DataTypes datatype) |
| Sets the integer type used in binary data headers.
|
|
void | setCompressor (Vtk::CompressorTypes compressor, int level=-1) |
|
|
void | writeData (std::ofstream &out, std::vector< pos_type > &offsets, VtkFunction const &fct, PositionTypes type, std::optional< std::size_t > timestep={}) const |
|
void | writeDataAppended (std::ofstream &out, std::vector< std::uint64_t > &blocks) const |
|
void | writePoints (std::ofstream &out, std::vector< pos_type > &offsets, std::optional< std::size_t > timestep={}) const |
|
void | writeAppended (std::ofstream &out, std::vector< pos_type > const &offsets) const |
|
template<class HeaderType , class FloatType > |
std::uint64_t | writeValuesAppended (std::ofstream &out, std::vector< FloatType > const &values) const |
|
template<class T > |
void | writeValuesAscii (std::ofstream &out, std::vector< T > const &values) const |
|
void | writeHeader (std::ofstream &out, std::string const &type) const |
|
std::string | getNames (std::vector< VtkFunction > const &data) const |
| Return PointData/CellData attributes for the name of the first scalar/vector/tensor DataArray.
|
|
std::string | getEndian () const |
|
std::string | getFileExtension () const |
|
Vtk::FormatTypes | getFormat () const |
|
Vtk::DataTypes | getDatatype () const |
|
auto | comm () const |
|
template<class GV, class DC>
class Dune::VtkWriterInterface< GV, DC >
Interface for file writers for the Vtk XML file formats.
- Template Parameters
-
GV | Model of Dune::GridView |
DC | Model of DataCollectorInterface |
template<class GV , class DC >
template<class Function , class... Args>
Attach cell data to the writer.
Attach a global function to the writer that will be evaluated at cell centers. The global function must be assignable to the function wrapper Vtk::Function. Additional argument for output datatype and number of components can be passed. See Vtk::Function Constructor for possible arguments.
- Parameters
-
fct | A GridFunction, LocalFunction, or Dune::VTKFunction |
args... | Additional arguments, like name , numComponents , dataType or Vtk::FieldInfo |
template<class GV , class DC >
template<class Function , class... Args>
Attach point data to the writer.
Attach a global function to the writer that will be evaluated at grid points (vertices and higher order points). The global function must be assignable to the function wrapper Vtk::Function. Additional argument for output datatype and number of components can be passed. See Vtk::Function Constructor for possible arguments.
- Parameters
-
fct | A GridFunction, LocalFunction, or Dune::VTKFunction |
args... | Additional arguments, like name , numComponents , dataType or Vtk::FieldInfo |