MRPT  1.9.9
CMRVisualizer.h
Go to the documentation of this file.
1 /* +------------------------------------------------------------------------+
2  | Mobile Robot Programming Toolkit (MRPT) |
3  | http://www.mrpt.org/ |
4  | |
5  | Copyright (c) 2005-2018, Individual contributors, see AUTHORS file |
6  | See: http://www.mrpt.org/Authors - All rights reserved. |
7  | Released under BSD License. See details in http://www.mrpt.org/License |
8  +------------------------------------------------------------------------+ */
9 #ifndef CMRVISUALIZER_H
10 #define CMRVISUALIZER_H
11 
12 #include <iostream>
13 
16 #include <utility>
17 
18 namespace mrpt::graphs::detail
19 {
20 // (Dummy) standard version
21 //////////////////////////////////////////////////////////
22 
23 /**\brief Wrapper class that provides visualization of a network of poses that
24  * have been registered by many graphSLAM agents/robots
25  *
26  * \note This is a dummy 4 template arguments version of the CMRVisualizer
27  * class just to silence GCC warnings on conversions.
28  * For implementation details users should see its specialized version that
29  * runs specifically for TMRSlamNodeAnnotations as the 3rd template argument.
30  *
31  */
32 template <
33  class CPOSE, // Type of edges
34  class MAPS_IMPLEMENTATION, // Use std::map<> vs. std::vector<>
35  class NODE_ANNOTATIONS = mrpt::graphs::detail::TMRSlamNodeAnnotations,
36  class EDGE_ANNOTATIONS = mrpt::graphs::detail::edge_annotations_empty>
38  : public CVisualizer<
39  CPOSE, MAPS_IMPLEMENTATION, NODE_ANNOTATIONS, EDGE_ANNOTATIONS>
40 {
41  public:
42  using parent = CVisualizer<
43  CPOSE, MAPS_IMPLEMENTATION, NODE_ANNOTATIONS, EDGE_ANNOTATIONS>;
45  CPOSE, MAPS_IMPLEMENTATION, NODE_ANNOTATIONS, EDGE_ANNOTATIONS>;
46 
47  CMRVisualizer(const GRAPH_T& graph_in);
48 
50  void drawNodePoints(
52  const mrpt::system::TParametersDouble* viz_params = NULL) const;
53  void drawEdges(
55  const mrpt::system::TParametersDouble* viz_params = NULL) const;
56 
57  private:
58 };
59 
60 // Specialized version
61 //////////////////////////////////////////////////////////
62 
63 template <
64  class CPOSE, // Type of edges
65  class MAPS_IMPLEMENTATION, // Use std::map<> vs. std::vector<>
66  class EDGE_ANNOTATIONS>
68  CPOSE, MAPS_IMPLEMENTATION, TMRSlamNodeAnnotations, EDGE_ANNOTATIONS>
69  : public CVisualizer<
70  CPOSE, MAPS_IMPLEMENTATION, TMRSlamNodeAnnotations, EDGE_ANNOTATIONS>
71 {
72  public:
73  using parent = CVisualizer<
74  CPOSE, MAPS_IMPLEMENTATION, TMRSlamNodeAnnotations, EDGE_ANNOTATIONS>;
76  CPOSE, MAPS_IMPLEMENTATION, TMRSlamNodeAnnotations, EDGE_ANNOTATIONS>;
77 
78  CMRVisualizer(const GRAPH_T& graph_in);
79 
81  void drawNodePoints(
83  const mrpt::system::TParametersDouble* viz_params = NULL) const;
84  void drawEdges(
86  const mrpt::system::TParametersDouble* viz_params = NULL) const;
87 
88  private:
89 };
90 }
92 
93 #endif /* end of include guard: CMRVISUALIZER_H */
94 
95 
void drawEdges(mrpt::opengl::CSetOfObjects::Ptr &object, const mrpt::system::TParametersDouble *viz_params=NULL) const
void drawNodePoints(mrpt::opengl::CSetOfObjects::Ptr &object, const mrpt::system::TParametersDouble *viz_params=NULL) const
Base class for C*Visualizer classes.
A directed graph of pose constraints, with edges being the relative poses between pairs of nodes iden...
Internal functions for MRPT.
CMRVisualizer(const GRAPH_T &graph_in)
Struct to be used as the NODE_ANNOTATIONS template argument in CNetworkOfPoses class instances for us...
Wrapper class that provides visualization of a network of poses that have been registered by many gra...
Definition: CMRVisualizer.h:37



Page generated by Doxygen 1.8.14 for MRPT 1.9.9 Git: 7d5e6d718 Fri Aug 24 01:51:28 2018 +0200 at lun nov 2 08:35:50 CET 2020