Edge.h
Go to the documentation of this file.
00001 #ifndef EDGE_H
00002 #define EDGE_H
00003 
00004 #include <vector>
00005 
00006 #include "AprilTags/FloatImage.h"
00007 
00008 namespace AprilTags {
00009 
00010 class FloatImage;
00011 class UnionFindSimple;
00012 
00013 using std::min;
00014 using std::max;
00015 
00017 
00020 class Edge {
00021 public:
00022   static float const minMag;   
00023   static float const maxEdgeCost;   
00024   static int const WEIGHT_SCALE; // was 10000
00025   static float const thetaThresh; 
00026   static float const magThresh; 
00027 
00028   int pixelIdxA;
00029   int pixelIdxB;
00030   int cost;
00031 
00033   Edge() : pixelIdxA(), pixelIdxB(), cost() {}
00034 
00036   inline bool operator< (const Edge &other) const { return (cost < other.cost); }
00037 
00039 
00045   static int edgeCost(float  theta0, float theta1, float mag1);
00046 
00048   static void calcEdges(float theta0, int x, int y,
00049                         const FloatImage& theta, const FloatImage& mag,
00050                         std::vector<Edge> &edges, size_t &nEdges);
00051 
00053   static void mergeEdges(std::vector<Edge> &edges, UnionFindSimple &uf, float tmin[], float tmax[], float mmin[], float mmax[]);
00054 
00055 };
00056 
00057 } // namespace
00058 
00059 #endif


apriltags
Author(s): Michael Kaess, Hordur Johannson
autogenerated on Thu Jun 6 2019 20:53:23