Visu.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include <regex>
4 #include <unordered_map>
5 
8 
9 #include "datatypes/Location.h"
10 
12 {
13 
14  class Visu
15  {
16  public:
18  {
20  std::optional<Eigen::Vector3f> extents;
21  };
22 
24 
25  {
26  }
27 
28  ~Visu() = default;
29 
31  locationsToLayer(const std::string& layerName,
32  const std::map<std::string, FramedLocationData>& locationData) const;
33 
35  const std::string& layerName,
36  const std::map<std::string, Eigen::Matrix4f>& locationGlobalPoses) const;
37 
39  const std::string& layerName,
40  const std::map<std::string, std::pair<Eigen::Matrix4f, Eigen::Vector3f>>&
41  locationGlobalPosesAndExtends) const;
42 
43  protected:
45  const std::string& id,
46  const Eigen::Matrix4f& locationGlobalPose) const;
47 
49  const std::string& id,
50  const Eigen::Matrix4f& locationGlobalPose,
51  const Eigen::Vector3f& extends) const;
52 
53  public:
54  struct Settings
55  {
56  // FramedLocation
58 
59  // FramedBoxedLocation
61 
62  } settings;
63 
64  protected:
66 
67  private:
68  const std::regex pattern = std::regex(R"(^[^:]+\/([^:]+?):[^:]+?$)");
69  mutable std::set<std::string> unique_affordances;
70  };
71 } // namespace armarx::priorknowledge::util::location
Client.h
armarx::priorknowledge::util::location::Visu::Visu
Visu(viz::Client &arviz)
Definition: Visu.h:23
armarx::priorknowledge::util::location::Visu::framedBoxedLocationsToLayer
viz::Layer framedBoxedLocationsToLayer(const std::string &layerName, const std::map< std::string, std::pair< Eigen::Matrix4f, Eigen::Vector3f >> &locationGlobalPosesAndExtends) const
Definition: Visu.cpp:95
armarx::priorknowledge::util::location::Visu::FramedLocationData::extents
std::optional< Eigen::Vector3f > extents
Definition: Visu.h:20
armarx::priorknowledge::util::location::Visu::Settings::framedBoxedLocationColor
viz::Color framedBoxedLocationColor
Definition: Visu.h:60
GfxTL::Matrix4f
MatrixXX< 4, 4, float > Matrix4f
Definition: MatrixXX.h:650
ScopedClient.h
armarx::priorknowledge::util::location::Visu
Definition: Visu.h:14
armarx::priorknowledge::util::location::Visu::addFramedBoxedLocationToLayer
void addFramedBoxedLocationToLayer(viz::Layer &, const std::string &id, const Eigen::Matrix4f &locationGlobalPose, const Eigen::Vector3f &extends) const
Definition: Visu.cpp:25
armarx::priorknowledge::util::location::Visu::FramedLocationData
Definition: Visu.h:17
armarx::priorknowledge::util::location::Visu::arviz
viz::Client & arviz
Definition: Visu.h:65
armarx::priorknowledge::util::location::Visu::Settings
Definition: Visu.h:54
Color
uint32_t Color
RGBA color.
Definition: color.h:8
armarx::viz::Color
Definition: Color.h:12
armarx::priorknowledge::util::location::Visu::FramedLocationData::globalPose
Eigen::Matrix4f globalPose
Definition: Visu.h:19
Location.h
armarx::priorknowledge::util::location::Visu::settings
struct armarx::priorknowledge::util::location::Visu::Settings settings
armarx::priorknowledge::util::location::Visu::Settings::framedLocationArrowColor
viz::Color framedLocationArrowColor
Definition: Visu.h:57
armarx::priorknowledge::util::location::Visu::~Visu
~Visu()=default
armarx::priorknowledge::util::location::Visu::addFramedLocationToLayer
void addFramedLocationToLayer(viz::Layer &, const std::string &id, const Eigen::Matrix4f &locationGlobalPose) const
Definition: Visu.cpp:11
armarx::priorknowledge::util::location::Visu::locationsToLayer
viz::Layer locationsToLayer(const std::string &layerName, const std::map< std::string, FramedLocationData > &locationData) const
Definition: Visu.cpp:62
armarx::viz::Color::green
static Color green(int g=255, int a=255)
Definition: Color.h:94
armarx::viz::Client
Definition: Client.h:117
armarx::priorknowledge::util::location
Definition: Visu.cpp:8
armarx::viz::Layer
Definition: Layer.h:12
armarx::priorknowledge::util::location::Visu::framedLocationsToLayer
viz::Layer framedLocationsToLayer(const std::string &layerName, const std::map< std::string, Eigen::Matrix4f > &locationGlobalPoses) const
Definition: Visu.cpp:81