Map.hpp
Go to the documentation of this file.
00001 // Copyright (c) 2013-2014 by Wayne C. Gramlich.  All rights reserved.
00002 
00003 #if !defined(MAP_H_INCLUDED)
00004 #define MAP_H_INCLUDED 1
00005 
00006 #include <map>
00007 #include <vector>
00008 
00009 #include "File.hpp"
00010 #include "Location.hpp"
00011 
00013 typedef struct Map__Struct *Map;
00014 
00015 #include "Arc.hpp"
00016 #include "Fiducials.hpp"
00017 
00018 class CameraTag;
00019 class Tag;
00020 class TagHeight;
00021 
00023 struct Map__Struct {
00025     Fiducials_Arc_Announce_Routine arc_announce_routine;
00026 
00028     std::vector<Arc*> all_arcs;
00029 
00031     std::vector<Tag*> all_tags;
00032 
00034     void *announce_object;
00035 
00037     std::map<std::pair<unsigned int, unsigned int>, Arc*> arcs_;
00038 
00040     unsigned int changes_count;
00041 
00043     String_Const file_base;
00044 
00046     String_Const file_path;
00047 
00049     bool image_log;
00050 
00052     bool is_changed;
00053 
00055     bool is_saved;
00056 
00058     std::vector<Arc*> pending_arcs;
00059 
00061     Fiducials_Tag_Announce_Routine tag_announce_routine;
00062 
00064     std::vector<TagHeight*> tag_heights;
00065 
00067     std::map<unsigned int, Tag*> tags_;
00068 
00070     Arc *temporary_arc;
00071 
00073     unsigned int visit;
00074 };
00075 
00076 // *Map* routines:
00077 
00078 extern void Map__arc_announce(
00079   Map map, Arc *arc, CV_Image image, unsigned int sequence_number);
00080 extern void Map__arc_append(Map map, Arc *arc);
00081 extern Arc * Map__arc_lookup(Map map, Tag *from, Tag *to);
00082 extern unsigned int Map__arc_update(Map map, CameraTag * camera_from,
00083   CameraTag * camera_to, CV_Image image, unsigned int sequence_number);
00084 extern bool Map__equals(Map map1, Map map2);
00085 extern Map Map__create(String_Const map_path, String_Const map_base,
00086   void *announce_object, Fiducials_Arc_Announce_Routine arc_announce_routine,
00087   Fiducials_Tag_Announce_Routine tag_announce_routine,
00088   String_Const tag_heights_file_name, String_Const from);
00089 extern void Map__free(Map map);
00090 extern TagHeight * Map__tag_height_lookup(Map map, unsigned int id);
00091 extern void Map__image_log(Map map, CV_Image image, unsigned int sequence_number);
00092 extern void Map__restore(Map map, File in_file);
00093 extern void Map__save(Map map);
00094 extern void Map__sort(Map map);
00095 extern void Map__svg_write(
00096   Map map, String_Const svg_base_name, std::vector<Location*> &locations);
00097 extern void Map__tag_heights_xml_read(
00098   Map map, String_Const tag_heights_file_name);
00099 extern void Map__tag_announce(
00100   Map map, Tag *tag, bool visible, CV_Image image,
00101   unsigned int sequence_number);
00102 extern Tag * Map__tag_lookup(Map map, unsigned int tag_id);
00103 extern void Map__update(Map map, CV_Image image, unsigned int sequence_number);
00104 extern void Map__write(Map map, File out_file);
00105 
00106 #endif // !defined(MAP_H_INCLUDED)


fiducial_lib
Author(s): Wayne Gramlich
autogenerated on Thu Jun 6 2019 18:08:04