AQUAgpusph 4.1.2
|
VTK particles data files loader/saver. More...
#include <InputOutput/VTK.h>
Public Member Functions | |
VTK (ProblemSetup &sim_data, unsigned int iset, unsigned int offset, unsigned int n=0) | |
Constructor. | |
~VTK () | |
Destructor. | |
void | save (float t) |
Save the data. | |
void | load () |
Load the data. | |
void | waitForSavers () |
Wait for the parallel saving threads. | |
Public Member Functions inherited from Aqua::InputOutput::Particles | |
Particles (ProblemSetup &sim_data, unsigned int iset, unsigned int offset, unsigned int n=0) | |
Constructor. | |
virtual | ~Particles () |
Destructor. | |
const std::string | file () |
Get the last printed file path. | |
unsigned int | n () |
Get the number of particles managed by this instance. | |
virtual void | waitForSavers () |
Wait for the eventual parallel saving threads. | |
virtual void | save (float t)=0 |
Save the data. | |
virtual void | load ()=0 |
Load the data. | |
Additional Inherited Members | |
Protected Member Functions inherited from Aqua::InputOutput::Particles | |
ProblemSetup & | simData () |
Get the simulation data structure. | |
void | n (unsigned int n) |
Set the number of particles managed by this instance. | |
const uivec2 | bounds () const |
Get the particle index bounds of the "set of particles" managed by this class. | |
const unsigned int | setId () const |
Get the "particles set" index associated with this class. | |
void | loadDefault () |
Register some default arrays: | |
void | file (const std::string filename) |
Set the file name. | |
unsigned int | file (const std::string basename, unsigned int start_index, unsigned int digits=5) |
std::vector< void * > | download (std::vector< std::string > fields) |
Protected Member Functions inherited from Aqua::InputOutput::InputOutput | |
InputOutput () | |
Constructor. | |
virtual | ~InputOutput () |
Destructor. | |
VTK particles data files loader/saver.
VTK is a visualization format, to learn more about it please visit the following web page:
This type of files can be easily post-processed with Paraview:
The fields to be saved/loaded are:
Aqua::InputOutput::VTK::VTK | ( | ProblemSetup & | sim_data, |
unsigned int | iset, | ||
unsigned int | offset, | ||
unsigned int | n = 0 |
||
) |
Constructor.
sim_data | Simulation data |
iset | Particles set index. |
offset | First particle managed by this saver/loader. |
n | Number of particles managed by this saver/loader. If 0, the number of particles will be obtained from the input file (thus only valid for loaders) |
Aqua::InputOutput::VTK::~VTK | ( | ) |
Destructor.
|
virtual |
Load the data.
Implements Aqua::InputOutput::InputOutput.
|
virtual |
|
virtual |
Wait for the parallel saving threads.
VTK saver is launching parallel threads to save the data in an asynchronous way, significantly improving the performance. Therefore, AQUAgpusph shall wait them to finish before proceeding to destroy the data
Reimplemented from Aqua::InputOutput::Particles.