Visu.h
Go to the documentation of this file.
1/*
2 * This file is part of ArmarX.
3 *
4 * ArmarX is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License version 2 as
6 * published by the Free Software Foundation.
7 *
8 * ArmarX is distributed in the hope that it will be useful, but
9 * WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
12 *
13 * You should have received a copy of the GNU General Public License
14 * along with this program. If not, see <http://www.gnu.org/licenses/>.
15 *
16 * @package Navigation::ArmarXObjects::NavigationMemory
17 * @author Rainer Kartmann ( rainer dot kartmann at kit dot edu )
18 * @date 2021
19 * @copyright http://www.gnu.org/licenses/gpl-2.0.txt
20 * GNU General Public License
21 */
22
23#pragma once
24
25#include <map>
26#include <memory>
27#include <string>
28#include <vector>
29
30#include <SimoxUtility/color/Color.h>
31
34
43
46
48{
49 class GraphVisu;
50}
51
53{
54
55 class Visu
56 {
57 public:
65 ~Visu();
66
67
68 void drawLocations(std::vector<viz::Layer>& layers);
70 std::vector<viz::Layer>& layers);
71
72 void drawGraphs(std::vector<viz::Layer>& layers);
74 std::vector<viz::Layer>& layers);
75 void drawCostmaps(std::vector<viz::Layer>& layers, float zOffset);
76 void drawHumans(std::vector<viz::Layer>& layers,
77 bool visuTransparent,
78 Duration maxAge);
79
80 void drawRooms(std::vector<viz::Layer>& layers);
81
82 void drawLaserScannerFeatures(std::vector<viz::Layer>& layers);
83
85
92
93 std::unique_ptr<navigation::graph::GraphVisu> visu;
94
95 private:
96 void
97 drawRoom(viz::Layer& layer, const algorithms::Room& room, const simox::Color& color) const;
98
99 void
100 drawHumansInLayer(const human::Humans& humans, viz::Layer& layer, bool visuTransparent);
101
103 const std::vector<ObjectInfo>& info,
104 viz::Layer& layer);
106 const std::vector<ObjectInfo>& info,
107 std::vector<viz::Layer>& layers);
108
109
110 std::map<std::string, DateTime> lastCostmapVisualization_;
111 };
112
113
114} // namespace armarx::navigation::memory
Represents a duration.
Definition Duration.h:17
void drawLaserScannerFeatures(std::vector< viz::Layer > &layers)
Definition Visu.cpp:389
std::unique_ptr< navigation::graph::GraphVisu > visu
Definition Visu.h:93
const armem::server::wm::CoreSegment & costmapSegment
Definition Visu.h:88
const armem::server::wm::CoreSegment & graphSegment
Definition Visu.h:87
const armem::server::wm::CoreSegment & roomsSegment
Definition Visu.h:90
void drawRooms(std::vector< viz::Layer > &layers)
Definition Visu.cpp:351
const armem::server::wm::CoreSegment & humanSegment
Definition Visu.h:89
viz::ScopedClient arviz
Definition Visu.h:84
const armem::server::wm::CoreSegment & locSegment
Definition Visu.h:86
void drawLocations(std::vector< viz::Layer > &layers)
Definition Visu.cpp:179
const armem::server::wm::CoreSegment & laserScannerFeaturesSegment
Definition Visu.h:91
void drawCostmaps(std::vector< viz::Layer > &layers, float zOffset)
Definition Visu.cpp:243
void drawGraphs(std::vector< viz::Layer > &layers)
Definition Visu.cpp:212
Visu(viz::Client &arviz, const armem::server::wm::CoreSegment &locSegment, const armem::server::wm::CoreSegment &graphSegment, const armem::server::wm::CoreSegment &costmapSegment, const armem::server::wm::CoreSegment &humanSegment, const armem::server::wm::CoreSegment &roomsSegment, const armem::server::wm::CoreSegment &laserScannerFeaturesSegment)
Definition Visu.cpp:84
void drawHumans(std::vector< viz::Layer > &layers, bool visuTransparent, Duration maxAge)
Definition Visu.cpp:288
Provides access to the armarx::objpose::ObjectPoseStorageInterface (aka the object memory).
viz::Client that will delete (clear) committed layers when destroyed.
This file is part of ArmarX.
Definition Visu.h:48
std::vector< Human > Humans
Definition types.h:48
std::map< ObjectID, ObjectPose > ObjectPoseMap