ls1-MarDyn
ls1-MarDyn molecular dynamics code
Public Member Functions | List of all members
VTKMoleculeWriterImplementation Class Reference

#include <VTKMoleculeWriterImplementation.h>

Public Member Functions

 VTKMoleculeWriterImplementation (int rank, bool plotCenters=false)
 
void initializeVTKFile ()
 
void plotMolecule (Molecule &molecule)
 
void writeVTKFile (const std::string &fileName)
 
void initializeParallelVTKFile (const std::vector< std::string > &fileNames)
 
void writeParallelVTKFile (const std::string &fileName)
 
bool isVTKFileInitialized ()
 
bool isParallelVTKFileInitialized ()
 
unsigned int getNumMoleculesPlotted ()
 

Detailed Description

This class contains the actual functionality for writing molecules as vtk unstructured grid data. Molecules are written as the points of the unstructured grid, thus there are no grid cells, as the molecules don't really form a grid.

It acts as an adapter to the serialization classes generated by codesynthesis xsd.

Constructor & Destructor Documentation

◆ VTKMoleculeWriterImplementation()

VTKMoleculeWriterImplementation::VTKMoleculeWriterImplementation ( int  rank,
bool  plotCenters = false 
)
Parameters
rankthe MPI rank of the process

Member Function Documentation

◆ initializeParallelVTKFile()

void VTKMoleculeWriterImplementation::initializeParallelVTKFile ( const std::vector< std::string > &  fileNames)

Initialize the data structures to write a parallel vtk file (i.e. a meta file describing the data and structure of the file a single node creates).

Parameters
fileNamesthe names of the sequential files which are to be referenced

◆ initializeVTKFile()

void VTKMoleculeWriterImplementation::initializeVTKFile ( )

TODO: there's redundancy in adding the data members (the same has to be done for the parallel VTK File. -> use array of structs?

◆ plotMolecule()

void VTKMoleculeWriterImplementation::plotMolecule ( Molecule molecule)

Plot a molecule.

Parameters
moleculethe molecule to plot

◆ writeParallelVTKFile()

void VTKMoleculeWriterImplementation::writeParallelVTKFile ( const std::string &  fileName)

Write the xml-tree to a file on disc.

Parameters
fileNamethe name of the file written

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