A mean viewer. More...
#include <bbgm_viewer.h>
Public Member Functions | |
virtual vcl_string | name () const |
Return the name of this view. | |
bool | probe (const bbgm_image_sptr &dimg) const |
Probe to see if this viewer can handle this image type. | |
unsigned int | max_components (const bbgm_image_sptr &dimg) const |
Return the maximum number of components if a mixture. | |
bool | apply (const bbgm_image_sptr &dimg, vil_image_view< double > &image) const |
Apply the operations to the distribution image to produce a vil image. | |
void | set_failure_value (const vnl_vector< double > &val) |
Set the value for failure at a pixel. | |
void | set_active_component (unsigned int val) |
Set the value for failure at a pixel. | |
unsigned int | active_component () const |
Return the active component. | |
void | ref () |
void | unref () |
int | get_references () const |
bool | is_referenced () const |
Static Public Member Functions | |
static bool | register_view_maker (const bbgm_view_maker_sptr &vm) |
Register a new view_maker. | |
static bbgm_view_maker_sptr | find_view_maker (const vcl_type_info &dist_type) |
Return a pointer to the view_maker that applies to this image type. | |
Protected Member Functions | |
virtual bbgm_view_maker_sptr | find_vm (const vcl_type_info &dist_type) const |
A virtual wrapper around the static find function. | |
Protected Attributes | |
double | fail_val_ [3] |
the data used when a pixel fails the operation. | |
unsigned int | active_component_ |
the active component to use if the distribution is a mixture. | |
bbgm_view_maker_sptr | view_maker_ |
a cached pointer to the view_maker object last found. | |
Static Private Attributes | |
static vcl_vector < bbgm_view_maker_sptr > | reg_vms |
The registered view maker objects. |
A mean viewer.
Definition at line 66 of file bbgm_viewer.h.
unsigned int bbgm_viewer::active_component | ( | ) | const [inline, inherited] |
Return the active component.
Definition at line 47 of file bbgm_viewer.h.
bool bbgm_viewer::apply | ( | const bbgm_image_sptr & | dimg, |
vil_image_view< double > & | image | ||
) | const [inherited] |
Apply the operations to the distribution image to produce a vil image.
Definition at line 40 of file bbgm_viewer.cxx.
bbgm_view_maker_sptr bbgm_mean_viewer::find_view_maker | ( | const vcl_type_info & | dist_type | ) | [static] |
Return a pointer to the view_maker that applies to this image type.
Return a null pointer if no such view_maker is found
Definition at line 84 of file bbgm_viewer.cxx.
virtual bbgm_view_maker_sptr bbgm_mean_viewer::find_vm | ( | const vcl_type_info & | dist_type | ) | const [inline, protected, virtual] |
A virtual wrapper around the static find function.
Implements bbgm_viewer.
Definition at line 85 of file bbgm_viewer.h.
unsigned int bbgm_viewer::max_components | ( | const bbgm_image_sptr & | dimg | ) | const [inherited] |
Return the maximum number of components if a mixture.
If not a mixture return 1
Definition at line 26 of file bbgm_viewer.cxx.
virtual vcl_string bbgm_mean_viewer::name | ( | ) | const [inline, virtual] |
bool bbgm_viewer::probe | ( | const bbgm_image_sptr & | dimg | ) | const [inherited] |
Probe to see if this viewer can handle this image type.
Definition at line 12 of file bbgm_viewer.cxx.
bool bbgm_mean_viewer::register_view_maker | ( | const bbgm_view_maker_sptr & | vm | ) | [static] |
Register a new view_maker.
Definition at line 62 of file bbgm_viewer.cxx.
void bbgm_viewer::set_active_component | ( | unsigned int | val | ) | [inline, inherited] |
Set the value for failure at a pixel.
Definition at line 44 of file bbgm_viewer.h.
void bbgm_viewer::set_failure_value | ( | const vnl_vector< double > & | val | ) | [inline, inherited] |
Set the value for failure at a pixel.
Definition at line 40 of file bbgm_viewer.h.
unsigned int bbgm_viewer::active_component_ [protected, inherited] |
the active component to use if the distribution is a mixture.
Definition at line 58 of file bbgm_viewer.h.
double bbgm_viewer::fail_val_[3] [protected, inherited] |
the data used when a pixel fails the operation.
Definition at line 56 of file bbgm_viewer.h.
vcl_vector< bbgm_view_maker_sptr > bbgm_mean_viewer::reg_vms [static, private] |
The registered view maker objects.
initialize the static vector of registered types.
Definition at line 92 of file bbgm_viewer.h.
bbgm_view_maker_sptr bbgm_viewer::view_maker_ [mutable, protected, inherited] |
a cached pointer to the view_maker object last found.
Definition at line 60 of file bbgm_viewer.h.