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

iptk::MaskFilter Class Reference

#include <maskFilter.h>

Inheritance diagram for iptk::MaskFilter:

Inheritance graph
[legend]
Collaboration diagram for iptk::MaskFilter:

Collaboration graph
[legend]
List of all members.

Detailed Description

A class encapsulating functions to perform filtering operations on images using masks.

An image has to be registered with an object of class MaskFilter before any filtering is done. The filtering is done on the registered image in place.i.e, the original/registered image is modified in the process.


Public Member Functions

 MaskFilter (void)
 Default Constructor.

 MaskFilter (const iptk::Image &im)
 Image registration Constructor.

 MaskFilter (const MaskFilter &mf)
 Copy constructor Though this constructor does not look like a reference copier, the image data is shared between the passed object(i.e the parameter to the copy constructor) and the new object.

virtual ~MaskFilter ()
 Do nothing destructor.

void setMask (const iptk::Mask &m)
 Set the filter and its type using this function.

virtual void process (void)
 The actual filtering function.

iptk::Image getResult (void)
 Returns the resulting image.


Protected Attributes

iptk::Mask MASK
 A protected data member to store the mask to be used for filtering purposes.


Constructor & Destructor Documentation

iptk::MaskFilter::MaskFilter void   ) 
 

Default Constructor.

Initialises the private member image to a null image. You will have to follow the initialisation by a defualt constructor by a call to the inherited setImage function.

iptk::MaskFilter::MaskFilter const iptk::Image im  ) 
 

Image registration Constructor.

Initialises the member image with the parameter im and hence registers it as the image.

virtual iptk::MaskFilter::~MaskFilter  )  [virtual]
 

Do nothing destructor.

Destructor does nothing at all as the default destructor would have been sufficient.


Member Function Documentation

iptk::Image iptk::MaskFilter::getResult void   )  [virtual]
 

Returns the resulting image.

As the registered image is itself modified in this case, the returned image is the modified registered image.

Reimplemented from iptk::IP_Function.

virtual void iptk::MaskFilter::process void   )  [virtual]
 

The actual filtering function.

If the mask has been previously set, then it processes the image. Else, the result of the filtering process is invalid/undefined. A repeated call to this function would mean succesive processing of the registered image in place.

Implements iptk::IP_Function.

void iptk::MaskFilter::setMask const iptk::Mask m  ) 
 

Set the filter and its type using this function.

Pass the filter type in mt and the mask size in maskSize. The mask is only set by reference and new memory is not initialised.


Member Data Documentation

iptk::Mask iptk::MaskFilter::MASK [protected]
 

A protected data member to store the mask to be used for filtering purposes.

The derived class has to override/define the setParams function which should set this mask object. The derived classes need not have to define their own process functions. Setting this iptk::Mask object correctly would suffice.


The documentation for this class was generated from the following file:
Generated on Mon Nov 22 11:12:42 2004 for ImprolaLib by doxygen 1.3.7