contrib/mul/mfpf/mfpf_edge_finder_builder.h
Go to the documentation of this file.
00001 #ifndef mfpf_edge_finder_builder_h_
00002 #define mfpf_edge_finder_builder_h_
00003 //:
00004 // \file
00005 // \brief Builder for mfpf_edge_finder objects.
00006 // \author Tim Cootes
00007 
00008 #include <mfpf/mfpf_point_finder_builder.h>
00009 #include <vgl/vgl_fwd.h>
00010 #include <vcl_iosfwd.h>
00011 
00012 //: Builder for mfpf_edge_finder objects.
00013 class mfpf_edge_finder_builder : public mfpf_point_finder_builder
00014 {
00015  private:
00016  public:
00017 
00018   //: Dflt ctor
00019   mfpf_edge_finder_builder();
00020 
00021   //: Destructor
00022   virtual ~mfpf_edge_finder_builder();
00023 
00024   //: Define region size in world co-ordinates
00025   //  Sets up ROI to cover given box (with samples at step_size()),
00026   //  with ref point at centre.
00027   //  Currently does nothing.
00028   virtual void set_region_size(double wi, double wj);
00029 
00030   //: Create new mfpf_edge_finder on heap
00031   virtual mfpf_point_finder* new_finder() const;
00032 
00033   //: Initialise building
00034   // Must be called before any calls to add_example(...)
00035   virtual void clear(unsigned n_egs);
00036 
00037   //: Add one example to the model
00038   virtual void add_example(const vimt_image_2d_of<float>& image,
00039                            const vgl_point_2d<double>& p,
00040                            const vgl_vector_2d<double>& u);
00041 
00042   //: Build object from the data supplied in add_example()
00043   virtual void build(mfpf_point_finder&);
00044 
00045   //: Initialise from a string stream
00046   virtual bool set_from_stream(vcl_istream &is);
00047 
00048   //: Version number for I/O
00049   short version_no() const;
00050 
00051   //: Name of the class
00052   virtual vcl_string is_a() const;
00053 
00054   //: Create a copy on the heap and return base class pointer
00055   virtual mfpf_point_finder_builder* clone() const;
00056 
00057   //: Print class to os
00058   virtual void print_summary(vcl_ostream& os) const;
00059 
00060   //: Save class to binary file stream
00061   virtual void b_write(vsl_b_ostream& bfs) const;
00062 
00063   //: Load class from binary file stream
00064   virtual void b_read(vsl_b_istream& bfs);
00065 };
00066 
00067 #endif