#ifndef autostitch_H__ #define autostitch_H__ #include "meowpp/Usage.h" #include "meowpp/colors/RGB_Space.h" #include "meowpp/geo/Vectors.h" #include "meowpp/gra/FeaturePoint.h" #include "meowpp/gra/FeaturePointsDetector.h" #include "meowpp/gra/FeaturePointsMatch.h" #include "meowpp/gra/FeaturePointsMatch_K_Match.h" #include "meowpp/oo/ObjBase.h" #include "meowpp/oo/ObjSelector.h" #include "meowpp/math/Vector.h" #include #include #include static const size_t FPSD_ID = 5; typedef std::vector > FeaturePoints; class MyFeaturePointsDetector: public meow::ObjBase { public: virtual meow::Usage usage() const = 0; virtual bool usage(meow::Usage const& usg) = 0; virtual FeaturePoints detect(meow::Bitmap const& bmp) = 0; }; class MyK_Match { private: meow::FeaturePointsMatch_K_Match _body; public: MyK_Match(); ~MyK_Match(); meow::Usage usage() const; bool usage(meow::Usage const& usg); meow::FeaturePointIndexPairs match( std::vector > >const& fp); }; class MyRansacCheck { private: static double threshold; std::vector > const* _from; std::vector > const* _to ; double a_, b_, c_, d_, e_, f_, A_, B_; double _w, _h; double r_, ang; public: static meow::Usage usage(); static bool usage(meow::Usage const& usg); MyRansacCheck(); MyRansacCheck(MyRansacCheck const& __rc); MyRansacCheck(std::vector > const* __from, std::vector > const* __to, double, double, double, double); ~MyRansacCheck(); meow::Vector vCalc(std::vector const& __sample) const; void rememberVCalc(std::vector const& __sample); bool ok(meow::FeaturePointIndexPair const& __m) const; double operator()(std::vector const& __sample, std::vector const& __data) const; bool check(); void print() const; meow::Vector2D to(meow::Vector2D const& __v) const; }; #endif // autostitch_H__