json_elements.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include <SimoxUtility/json.h>
4 #include <SimoxUtility/meta/EnumNames.hpp>
5 
6 #include <RobotAPI/interface/ArViz/Elements.h>
7 
8 namespace armarx::viz::data
9 {
10 
11  namespace ElementFlags
12  {
13  extern const simox::meta::IntEnumNames names;
14  }
15 
16  namespace ModelDrawStyle
17  {
18  extern const simox::meta::IntEnumNames names;
19  }
20 
21  void to_json(nlohmann::json& j, const ColoredPoint& coloredPoint);
22  void from_json(const nlohmann::json& j, ColoredPoint& coloredPoint);
23 
24 
25  // Elements
26 
27  void to_json(nlohmann::json& j, const ElementArrow& line);
28  void from_json(const nlohmann::json& j, ElementArrow& line);
29 
30 
31  void to_json(nlohmann::json& j, const ElementArrowCircle& arrowCircle);
32  void from_json(const nlohmann::json& j, ElementArrowCircle& arrowCircle);
33 
34 
35  void to_json(nlohmann::json& j, const ElementBox& box);
36  void from_json(const nlohmann::json& j, ElementBox& box);
37 
38 
39  void to_json(nlohmann::json& j, const ElementCylinder& cylinder);
40  void from_json(const nlohmann::json& j, ElementCylinder& cylinder);
41 
42 
43  void to_json(nlohmann::json& j, const ElementCylindroid& cylindroid);
44  void from_json(const nlohmann::json& j, ElementCylindroid& cylindroid);
45 
46 
47  void to_json(nlohmann::json& j, const ElementLine& line);
48  void from_json(const nlohmann::json& j, ElementLine& line);
49 
50 
51  void to_json(nlohmann::json& j, const ElementMesh& mesh);
52  void from_json(const nlohmann::json& j, ElementMesh& mesh);
53 
54 
55  void to_json(nlohmann::json& j, const ElementObject& object);
56  void from_json(const nlohmann::json& j, ElementObject& object);
57 
58 
59  void to_json(nlohmann::json& j, const ElementPointCloud& pointCloud);
60  void from_json(const nlohmann::json& j, ElementPointCloud& pointCloud);
61 
62 
63  void to_json(nlohmann::json& j, const ElementPolygon& polygon);
64  void from_json(const nlohmann::json& j, ElementPolygon& polygon);
65 
66 
67  void to_json(nlohmann::json& j, const ElementPose& pose);
68  void from_json(const nlohmann::json& j, ElementPose& pose);
69 
70 
71  void to_json(nlohmann::json& j, const ElementPath& path);
72  void from_json(const nlohmann::json& j, ElementPath& path);
73 
74 
75  void to_json(nlohmann::json& j, const ElementRobot& robot);
76  void from_json(const nlohmann::json& j, ElementRobot& robot);
77 
78 
79  void to_json(nlohmann::json& j, const ElementSphere& sphere);
80  void from_json(const nlohmann::json& j, ElementSphere& sphere);
81 
82 
83  void to_json(nlohmann::json& j, const ElementEllipsoid& sphere);
84  void from_json(const nlohmann::json& j, ElementEllipsoid& sphere);
85 
86 
87  void to_json(nlohmann::json& j, const ElementText& text);
88  void from_json(const nlohmann::json& j, ElementText& text);
89 
90 } // namespace armarx::viz::data
armarx::viz::data::from_json
void from_json(nlohmann::json const &j, RecordingBatchHeader &batch)
Definition: ArVizStorage.cpp:432
armarx::viz::data::ModelDrawStyle::names
const simox::meta::IntEnumNames names
Definition: json_elements.cpp:19
armarx::viz::data
Definition: ArVizStorage.cpp:418
armarx::viz::data::ElementFlags::names
const simox::meta::IntEnumNames names
Definition: json_elements.cpp:13
armarx::viz::data::to_json
void to_json(nlohmann::json &j, RecordingBatchHeader const &batch)
Definition: ArVizStorage.cpp:422