00001
00002 #ifndef vgel_multi_view_data_
00003 #define vgel_multi_view_data_
00004 #ifdef VCL_NEEDS_PRAGMA_INTERFACE
00005 #pragma interface
00006 #endif
00007
00008
00009
00010
00011
00012
00013
00014 #include <vcl_vector.h>
00015 #include <vcl_iosfwd.h>
00016 #include <mvl/NViewMatches.h>
00017 #include <vbl/vbl_ref_count.h>
00018
00019 template <class T>
00020 class vgel_multi_view_data: public vbl_ref_count
00021 {
00022 public:
00023 vgel_multi_view_data();
00024 vgel_multi_view_data(int nbviews);
00025
00026 vgel_multi_view_data(vgel_multi_view_data const& d)
00027 : vbl_ref_count(), nbviews_(d.nbviews_), nbfeatures_(d.nbfeatures_),
00028 size_vect_ft_(d.size_vect_ft_), matchnum_(d.matchnum_),
00029 closed_track_(d.closed_track_), MVM(d.MVM), all_pts(d.all_pts) {}
00030 ~vgel_multi_view_data();
00031
00032 void new_track();
00033 void close_track();
00034
00035 void set_params(int nbviews);
00036 void set(int view_num,int matchnum,T);
00037 void set(int view_num,T);
00038
00039 void get(int, vcl_vector<T> &);
00040 void get(int, int, vcl_vector<T> &,
00041 vcl_vector<T> &);
00042 void get(int, int, int, vcl_vector<T> &,
00043 vcl_vector<T> &,
00044 vcl_vector<T> &);
00045
00046 bool get_pred_match(int view_num,T obj,T & res);
00047 int get_nb_views() const {return nbviews_;}
00048
00049 void remove(int view_num, T match);
00050
00051 vcl_ostream& print(vcl_ostream& str);
00052
00053 private:
00054 int nbviews_;
00055 int nbfeatures_;
00056 int size_vect_ft_;
00057 int matchnum_;
00058 bool closed_track_;
00059
00060 NViewMatches MVM;
00061 vcl_vector<T> all_pts;
00062 };
00063
00064 #endif // vgel_multi_view_data_