This set of Matlab tools consists of some functions that I have found useful for basic image processing and blob analysis.
When working with binary objects (4-connected foreground regions), I have often found it useful to measure features from the boundary stored as a list of coordinates. In other words, sometimes it is better to work with a polygon defining the foreground-background boundary than to work with a black and white image of the object. The boundary of an object in a binary (black and white) image can be stored as a list of pixel corner coordinates. The function getboundarymex
The toolbox also contains selectobjectmex
imOut=selectobjectmex(imIn,n)
imOut
n
imIn
imOut=selectobjectmex(im>0.5,1)
Also included is code for watershed segmentation by flooding from selected sources, fast calculation of object centroids etc.
The usage of each the function is described by typing help function
at the MATLAB command prompt, where function
The M-file script kftoolsDemo
shows an example of the usage of all of the functions in this toolbox.
Download kftools.zip (119 kilobytes, last modified 24 October 2002)
Tested on Windows: MATLAB Version 5.3.0.10183 (R11) on PCWIN (28 March 2001)
Tested on Linux: MATLAB Version 6.0.0.88 (R12) on GLNX86 (28 August 2001)
Tested on Windows: MATLAB Version 6.0.0.88 (R12) on PCWIN (28 August 2001)
Disclaimer: You may find this code useful for research purposes, but I do not claim that it is robust!
kforbes@dip.ee.uct.ac.za