NetDEM v1.0
|
A class for converting between Particle objects and ParticleDataGPU structs. More...
#include <particle_parser_gpu.hpp>
Static Public Member Functions | |
static void | ClassToStruct (const Particle *const p_class, ParticleDataGPU *const p_struct) |
Converts a Particle object to a ParticleDataGPU struct. | |
static void | StructToClass (Particle *const p_class, const ParticleDataGPU *const p_struct, const std::unordered_map< int, Shape * > &shape_map) |
Converts a ParticleDataGPU struct to a Particle object. | |
A class for converting between Particle objects and ParticleDataGPU structs.
The ParticleParser class provides methods for converting between Particle objects and ParticleDataGPU structs, which are used for communication between MPI processes in the Peridigm code.
|
static |
Converts a Particle object to a ParticleDataGPU struct.
This static method converts a Particle object to a ParticleDataGPU struct, which can be used for communication between MPI processes.
p_class | The Particle object to convert. |
p_struct | The ParticleDataGPU struct to store the converted data in. |
|
static |
Converts a ParticleDataGPU struct to a Particle object.
This static method converts a ParticleDataGPU struct to a Particle object, using additional input data such as shape maps, etc.
p_class | The Particle object to store the converted data in. |
p_struct | The ParticleDataGPU struct to convert. |
shape_map | The unordered_map<int, Shape *> containing shape information for the particles. |