Jafar
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
taylor.hpp
00001 /* $Id: $ */
00002 #ifndef MODELER_TAYLOR_HPP
00003 #define MODELER_TAYLOR_HPP
00004 
00005 #include "modeler/vcgDeclarations.hpp"
00006 #include "fdetect/InterestFeature.hpp"
00007 #include "fdetect/DetectionResult.hpp"
00008 #include "gfm/MatchingResult.hpp"
00009 #include "gfm/Matcher.hpp"
00010 #include "image/Image.hpp"
00011 #include "fdetect/Detector.hpp"
00012 #include "localizer/planLocalizer.hpp"
00013 #include "camera/cameraContainer.hpp"
00014 #include "modeler/modeler.hpp"
00015 #include "modeler/jfr_import_ply.h"
00016 #include "modeler/jfr_io_mask.h"
00017 namespace jafar {
00018   namespace modeler {
00026     class Taylor : public modeler::Modeler {
00027 
00028     private:
00029       typedef fdetect_v2::InterestFeature<fdetect_v2::FloatDescriptor> Feature;
00031       std::map<unsigned int, fdetect_v2::DetectionResult<Feature> > sequence_detect;
00032       typedef std::map<unsigned int, fdetect_v2::DetectionResult<Feature> >::iterator detections_iter;
00034       bool is_updatable;
00036       gfm_v2::MatchingResult<Feature> current_result;
00038       unsigned int first_new_vertex_id;
00040       unsigned int first_new_shot_id;
00041       std::vector<unsigned int> transient_vertices;
00042     public:
00051       Taylor(JfrMesh& _mesh, camera::CameraType _type, const jblas::vec& _params,
00052              fdetect_v2::Detector<Feature>* _detector, 
00053              gfm_v2::Matcher<Feature>* _matcher )  : 
00054         Modeler(_mesh, _type, _params, _detector, _matcher), 
00055         is_updatable(false), first_new_vertex_id(0), first_new_shot_id(0)
00056       {
00057         populate();
00058       }
00059 
00066       Taylor(JfrMesh& _mesh,
00067              fdetect_v2::Detector<Feature>* _detector, 
00068              gfm_v2::Matcher<Feature>* _matcher )  : 
00069         Modeler(_mesh, _detector, _matcher), is_updatable(false), first_new_vertex_id(0), first_new_shot_id(0)
00070       {
00071         populate();
00072       }
00073 
00079       Taylor(JfrMesh& _mesh, camera::CameraType _type, const jblas::vec& _params) : 
00080         Modeler(_mesh, _type, _params), is_updatable(false), first_new_vertex_id(0), first_new_shot_id(0)
00081       {
00082         populate();
00083       }
00084 
00090       Taylor(const std::string& ply_mesh_file, 
00091              camera::CameraType _type, const jblas::vec& _params) : 
00092         Modeler(ply_mesh_file, _type, _params), is_updatable(false), first_new_vertex_id(0), first_new_shot_id(0)
00093       {
00094         populate();
00095       }
00096 
00100       Taylor(JfrMesh& _mesh) : 
00101         Modeler(_mesh), is_updatable(false), first_new_vertex_id(0), first_new_shot_id(0)
00102       {
00103         populate();
00104       }
00105 
00109       Taylor(const std::string& ply_mesh_file) : 
00110         Modeler(ply_mesh_file), is_updatable(false), first_new_vertex_id(0), first_new_shot_id(0)
00111       {
00112         populate();
00113       }
00114 
00116       void setDetector(fdetect_v2::Detector<Feature>* _detector)
00117       {
00118         detector = _detector;
00119       }
00120 
00122       void setMatcher(gfm_v2::Matcher<Feature>* _matcher)
00123       {
00124         matcher = _matcher;
00125       }
00126 
00128       void retouch(const image::Image &rqst, geom::T3D* pose);
00131       void retouch(camera::CameraType type, const jblas::vec& intrinsics, 
00132                    geom::T3D* extrinsics, const image::Image &rqst);
00133 
00134       
00140       void update();
00141 
00142 
00143     private:
00145       void populate();
00146 
00155       int add(fdetect_v2::DetectionResult<Feature> &dr);
00156     };
00157   };
00158 }
00159 
00160 #endif
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

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