View on GitHub

Vistle

Distributed Data-parallel Scientific Visualization in VR

objectmeta.h
Go to the documentation of this file.
1#ifndef OBJECTMETA_H
2#define OBJECTMETA_H
3
4#include <array>
5#include <vector>
6#include <memory>
7
8#include "archives_config.h"
9
10#include "export.h"
11#include "vector.h"
12#include "shm.h"
13
14namespace vistle {
15
17public:
18 Meta(int block = -1, int timestep = -1, int animationstep = -1, int iteration = -1, int execcount = -1,
19 int creator = -1);
20 int block() const { return m_block; }
21 void setBlock(int block) { m_block = block; }
22 int numBlocks() const { return m_numBlocks; }
23 void setNumBlocks(int num) { m_numBlocks = num; }
24 double realTime() const { return m_realtime; }
25 void setRealTime(double time) { m_realtime = time; }
26 int timeStep() const { return m_timestep; }
27 void setTimeStep(int timestep) { m_timestep = timestep; }
28 int numTimesteps() const { return m_numTimesteps; }
29 void setNumTimesteps(int num) { m_numTimesteps = num; }
30 int animationStep() const { return m_animationstep; }
31 void setAnimationStep(int step) { m_animationstep = step; }
32 void setNumAnimationSteps(int step) { m_numAnimationsteps = step; }
33 int numAnimationSteps() const { return m_numAnimationsteps; }
34 int iteration() const { return m_iteration; }
35 void setIteration(int iteration) { m_iteration = iteration; }
36 int executionCounter() const { return m_executionCount; }
37 void setExecutionCounter(int count) { m_executionCount = count; }
38 int creator() const { return m_creator; }
39 void setCreator(int id) { m_creator = id; }
40 Matrix4 transform() const;
41 void setTransform(const Matrix4 &transform);
42
43private:
44 int m_block, m_numBlocks, m_timestep, m_numTimesteps, m_animationstep, m_numAnimationsteps, m_iteration,
45 m_executionCount, m_creator;
46 double m_realtime;
47 std::array<double, 16> m_transform;
48
50 template<class Archive>
51 void serialize(Archive &ar);
52};
53
54V_COREEXPORT std::ostream &operator<<(std::ostream &out, const Meta &meta);
55
56#ifdef USE_BOOST_ARCHIVE
57extern template void V_COREEXPORT Meta::serialize<boost_iarchive>(boost_iarchive &ar);
58extern template void V_COREEXPORT Meta::serialize<boost_oarchive>(boost_oarchive &ar);
59#endif
60#ifdef USE_YAS
61extern template void V_COREEXPORT Meta::serialize<yas_iarchive>(yas_iarchive &ar);
62extern template void V_COREEXPORT Meta::serialize<yas_oarchive>(yas_oarchive &ar);
63#endif
64
65} // namespace vistle
66#endif
#define ARCHIVE_ACCESS
Definition: archives_config.h:465
Definition: objectmeta.h:16
int executionCounter() const
Definition: objectmeta.h:36
int iteration() const
Definition: objectmeta.h:34
void setAnimationStep(int step)
Definition: objectmeta.h:31
void setNumBlocks(int num)
Definition: objectmeta.h:23
int creator() const
Definition: objectmeta.h:38
double realTime() const
Definition: objectmeta.h:24
int block() const
Definition: objectmeta.h:20
void setRealTime(double time)
Definition: objectmeta.h:25
int numTimesteps() const
Definition: objectmeta.h:28
void setNumAnimationSteps(int step)
Definition: objectmeta.h:32
void setNumTimesteps(int num)
Definition: objectmeta.h:29
void setTimeStep(int timestep)
Definition: objectmeta.h:27
int timeStep() const
Definition: objectmeta.h:26
void setCreator(int id)
Definition: objectmeta.h:39
void setExecutionCounter(int count)
Definition: objectmeta.h:37
int numBlocks() const
Definition: objectmeta.h:22
int numAnimationSteps() const
Definition: objectmeta.h:33
int animationStep() const
Definition: objectmeta.h:30
void setIteration(int iteration)
Definition: objectmeta.h:35
void setBlock(int block)
Definition: objectmeta.h:21
#define V_COREEXPORT
Definition: export.h:9
void serialize(Archive &ar, vistle::Vector1 &v, const unsigned int version)
Definition: vector.h:105
Definition: allobjects.cpp:30
std::ostream & operator<<(std::ostream &out, const Meta &meta)
Definition: objectmeta.cpp:45
Eigen::Matrix< Scalar, 4, 4 > Matrix4
Definition: vector.h:44