Jafar
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
graphManager.hpp
00001 #ifndef GRAPHMANAGER_HPP
00002 #define GRAPHMANAGER_HPP
00003 
00004 #include <vector>
00005 #include <fstream>
00006 
00007 #include <boost/graph/graphviz.hpp>
00008 
00009 #include <kernel/threads.hpp>
00010 
00011 #include <graphmap/transformation.hpp>
00012 #include <graphmap/algorithms.hpp>
00013 #include <graphmap/graphManagerAbstract.hpp>
00014 #include <graphmap/inputManagerAbstract.hpp>
00015 #include <graphmap/outputManagerAbstract.hpp>
00016 
00017 #include <rtslam/quatTools.hpp>
00018 
00019 namespace jafar{
00020 namespace graphmap{
00021 
00022 class GraphManager : public GraphManagerAbstract
00023 {
00024 public:
00025   typedef typename std::vector<edge_descriptor> EdgeList;
00026 
00027   typedef typename boost::shared_ptr< InputManagerAbstract > input_manager_ptr_t;
00028   typedef typename std::vector< input_manager_ptr_t > InputManagerVector;
00029   typedef typename boost::shared_ptr< OutputManagerAbstract > output_manager_ptr_t;
00030   typedef typename std::vector< output_manager_ptr_t > OutputManagerVector;
00031 
00032   GraphManager(RobotId robotId);
00033 
00034   bool addNewEdge(RobotId from_robot, MapId from_map,
00035           RobotId to_robot, MapId to_map,
00036           Transformation t);
00037   void addInputManager(input_manager_ptr_t inputManagerPtr);
00038   void addOutputManager(output_manager_ptr_t outputManagerPtr);
00039   void updateGraph();
00040   void updateVertexData();
00041   void lookForLoopsFromEdge(edge_descriptor e);
00042   void optmizeLoops();
00043   EdgeList getLoop();
00044   void dumpToMemory();
00045   void saveGraphImage(std::string filename);
00046 
00047 
00048   kernel::VariableMutex<bool> exit;
00049   std::vector<EdgeList> _loops;
00050   InputManagerVector _input_managers;
00051   OutputManagerVector _output_managers;
00052 };
00053 
00054 }
00055 }
00056 
00057 #endif // GRAPHMANAGER_HPP
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated on Wed Oct 15 2014 00:37:20 for Jafar by doxygen 1.7.6.1
LAAS-CNRS