Main Page | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | File Members

vil3d_structuring_element Class Reference

#include <vil3d_structuring_element.h>

List of all members.


Detailed Description

Structuring element for morphology represented as a list of non-zero pixels.

Elements in box bounded by [min_i(),max_i()][min_j(),max_j()] Non-zero pixels are given by (p_i[k],p_j[k])

Definition at line 15 of file vil3d_structuring_element.h.

Public Member Functions

 vil3d_structuring_element ()
 vil3d_structuring_element (const vcl_vector< int > &p_i, const vcl_vector< int > &p_j, const vcl_vector< int > &p_k)
 Define elements { (p_i[a],p_j[a],p_k[a]) }.
void set (const vcl_vector< int > &p_i, const vcl_vector< int > &p_j, const vcl_vector< int > &p_k)
 Define elements { (p_i[a],p_j[a],p_k[a]) }.
void set_to_sphere (double r)
 Set to sphere of radius r.
void set_to_sphere_noniso (double r, double sx, double sy, double sz)
 Set to sphere of radius r, but with non isotropic voxel sizes.
void set_to_line_i (int ilo, int ihi)
 Set to line along i (ilo,0).
void set_to_line_j (int jlo, int jhi)
 Set to line along j (jlo,0).
void set_to_line_k (int klo, int khi)
 Set to line along k (klo,0).
const vcl_vector< int > & p_i () const
 i position of elements (i,j,k).
const vcl_vector< int > & p_j () const
 j position of elements (i,j,k).
const vcl_vector< int > & p_k () const
 k position of elements (i,j,k).
int min_i () const
 i range of elements is [min_i(),max_i()].
int max_i () const
 i range of elements is [min_i_,max_i()].
int min_j () const
 j range of elements is [min_j_,max_j()].
int max_j () const
 j range of elements is [min_j_,max_j()].
int min_k () const
 k range of elements is [min_k(),max_k()].
int max_k () const
 k range of elements is [min_k(),max_k()].

Private Attributes

vcl_vector< int > p_i_
 i position of elements (i,j,k).
vcl_vector< int > p_j_
 j position of elements (i,j,k).
vcl_vector< int > p_k_
 k position of elements (i,j,k).
int min_i_
 i range of elements is [min_i_,max_i_].
int max_i_
 i range of elements is [min_i_,max_i_].
int min_j_
 j range of elements is [min_j_,max_j_].
int max_j_
 j range of elements is [min_j_,max_j_].
int min_k_
 k range of elements is [min_k_,max_k_].
int max_k_
 k range of elements is [min_k_,max_k_].

Related Functions

(Note that these are not member functions.)

void vil3d_binary_closing (const vil3d_image_view< bool > &src_image, vil3d_image_view< bool > &dest_image, const vil3d_structuring_element &element)
 Applies morphological closing operation with given structuring element.
void vil3d_binary_dilate (const vil3d_image_view< bool > &src_image, vil3d_image_view< bool > &dest_image, const vil3d_structuring_element &element)
 Dilates src_image to produce dest_image (assumed single plane).
void vil3d_binary_erode (const vil3d_image_view< bool > &src_image, vil3d_image_view< bool > &dest_image, const vil3d_structuring_element &element)
 Erodes src_image to produce dest_image (assumed single plane).
void vil3d_binary_opening (const vil3d_image_view< bool > &src_image, vil3d_image_view< bool > &dest_image, const vil3d_structuring_element &element)
 Applies morphological opening operation with given structuring element.
template<class T>
void vil3d_max_product_filter (vil3d_image_view< T > &image, const vil3d_structuring_element &se, const vcl_vector< double > &f)
 Preforms raster scan through image, comparing each voxel with nbours.


Constructor & Destructor Documentation

vil3d_structuring_element::vil3d_structuring_element  )  [inline]
 

Definition at line 37 of file vil3d_structuring_element.h.

vil3d_structuring_element::vil3d_structuring_element const vcl_vector< int > &  p_i,
const vcl_vector< int > &  p_j,
const vcl_vector< int > &  p_k
 

Define elements { (p_i[a],p_j[a],p_k[a]) }.

Definition at line 12 of file vil3d_structuring_element.cxx.


Member Function Documentation

int vil3d_structuring_element::max_i  )  const [inline]
 

i range of elements is [min_i_,max_i()].

Definition at line 77 of file vil3d_structuring_element.h.

int vil3d_structuring_element::max_j  )  const [inline]
 

j range of elements is [min_j_,max_j()].

Definition at line 81 of file vil3d_structuring_element.h.

int vil3d_structuring_element::max_k  )  const [inline]
 

k range of elements is [min_k(),max_k()].

Definition at line 85 of file vil3d_structuring_element.h.

int vil3d_structuring_element::min_i  )  const [inline]
 

i range of elements is [min_i(),max_i()].

Definition at line 75 of file vil3d_structuring_element.h.

int vil3d_structuring_element::min_j  )  const [inline]
 

j range of elements is [min_j_,max_j()].

Definition at line 79 of file vil3d_structuring_element.h.

int vil3d_structuring_element::min_k  )  const [inline]
 

k range of elements is [min_k(),max_k()].

Definition at line 83 of file vil3d_structuring_element.h.

const vcl_vector<int>& vil3d_structuring_element::p_i  )  const [inline]
 

i position of elements (i,j,k).

Definition at line 68 of file vil3d_structuring_element.h.

const vcl_vector<int>& vil3d_structuring_element::p_j  )  const [inline]
 

j position of elements (i,j,k).

Definition at line 70 of file vil3d_structuring_element.h.

const vcl_vector<int>& vil3d_structuring_element::p_k  )  const [inline]
 

k position of elements (i,j,k).

Definition at line 72 of file vil3d_structuring_element.h.

void vil3d_structuring_element::set const vcl_vector< int > &  p_i,
const vcl_vector< int > &  p_j,
const vcl_vector< int > &  p_k
 

Define elements { (p_i[a],p_j[a],p_k[a]) }.

Definition at line 20 of file vil3d_structuring_element.cxx.

void vil3d_structuring_element::set_to_line_i int  ilo,
int  ihi
 

Set to line along i (ilo,0).

.(ihi,0).

Definition at line 82 of file vil3d_structuring_element.cxx.

void vil3d_structuring_element::set_to_line_j int  jlo,
int  jhi
 

Set to line along j (jlo,0).

.(jhi,0).

Definition at line 98 of file vil3d_structuring_element.cxx.

void vil3d_structuring_element::set_to_line_k int  klo,
int  khi
 

Set to line along k (klo,0).

.(khi,0).

Definition at line 114 of file vil3d_structuring_element.cxx.

void vil3d_structuring_element::set_to_sphere double  r  ) 
 

Set to sphere of radius r.

Select pixels in disk s.t. x*x+y*y+z*z<=r^r

Definition at line 49 of file vil3d_structuring_element.cxx.

void vil3d_structuring_element::set_to_sphere_noniso double  r,
double  sx,
double  sy,
double  sz
 

Set to sphere of radius r, but with non isotropic voxel sizes.

Select pixels in disk s.t. x*x+y*y+z*z<=r^r

Definition at line 65 of file vil3d_structuring_element.cxx.


Friends And Related Function Documentation

void vil3d_binary_closing const vil3d_image_view< bool > &  src_image,
vil3d_image_view< bool > &  dest_image,
const vil3d_structuring_element element
[related]
 

Applies morphological closing operation with given structuring element.

Applies dilation followed by erosion

Definition at line 15 of file vil3d_binary_closing.h.

void vil3d_binary_dilate const vil3d_image_view< bool > &  src_image,
vil3d_image_view< bool > &  dest_image,
const vil3d_structuring_element element
[related]
 

Dilates src_image to produce dest_image (assumed single plane).

Definition at line 10 of file vil3d_binary_dilate.cxx.

void vil3d_binary_erode const vil3d_image_view< bool > &  src_image,
vil3d_image_view< bool > &  dest_image,
const vil3d_structuring_element element
[related]
 

Erodes src_image to produce dest_image (assumed single plane).

Definition at line 11 of file vil3d_binary_erode.cxx.

void vil3d_binary_opening const vil3d_image_view< bool > &  src_image,
vil3d_image_view< bool > &  dest_image,
const vil3d_structuring_element element
[related]
 

Applies morphological opening operation with given structuring element.

Applies erosion followed by dilation

Definition at line 15 of file vil3d_binary_opening.h.

template<class T>
void vil3d_max_product_filter vil3d_image_view< T > &  image,
const vil3d_structuring_element se,
const vcl_vector< double > &  f
[related]
 

Preforms raster scan through image, comparing each voxel with nbours.

Runs through every voxel in raster order. Each voxel is compared with weighted versions of offset voxels, and is replaced with the maximum value.

Replace each voxel with max(im(i,j,k),max_a (f[a]*im(i+p_i[a],j+p_j[a],k+p_k[a],plane))

If a suitable combination of se and f is chosen, this performs half an 'exponential distance transform'. For an example of use, see vil3d_exp_distance_transform.

Definition at line 71 of file vil3d_max_product_filter.h.


Member Data Documentation

int vil3d_structuring_element::max_i_ [private]
 

i range of elements is [min_i_,max_i_].

Definition at line 26 of file vil3d_structuring_element.h.

int vil3d_structuring_element::max_j_ [private]
 

j range of elements is [min_j_,max_j_].

Definition at line 30 of file vil3d_structuring_element.h.

int vil3d_structuring_element::max_k_ [private]
 

k range of elements is [min_k_,max_k_].

Definition at line 34 of file vil3d_structuring_element.h.

int vil3d_structuring_element::min_i_ [private]
 

i range of elements is [min_i_,max_i_].

Definition at line 24 of file vil3d_structuring_element.h.

int vil3d_structuring_element::min_j_ [private]
 

j range of elements is [min_j_,max_j_].

Definition at line 28 of file vil3d_structuring_element.h.

int vil3d_structuring_element::min_k_ [private]
 

k range of elements is [min_k_,max_k_].

Definition at line 32 of file vil3d_structuring_element.h.

vcl_vector<int> vil3d_structuring_element::p_i_ [private]
 

i position of elements (i,j,k).

Definition at line 18 of file vil3d_structuring_element.h.

vcl_vector<int> vil3d_structuring_element::p_j_ [private]
 

j position of elements (i,j,k).

Definition at line 20 of file vil3d_structuring_element.h.

vcl_vector<int> vil3d_structuring_element::p_k_ [private]
 

k position of elements (i,j,k).

Definition at line 22 of file vil3d_structuring_element.h.


The documentation for this class was generated from the following files:
Generated on Thu Jan 10 14:44:14 2008 for contrib/mul/vil3d by  doxygen 1.4.4