No BSD License  

Highlights from
mdilate

2.0

2.0 | 2 ratings Rate this file 13 Downloads (last 30 days) File Size: 2.05 KB File ID: #131

mdilate

by

 

This has 2 files mdilate.m(performs dilation of image) and merode.m(performs erosion on image).

| Watch this File

File Information
Description

MDILATE Perform dilation on binary(2) or gray(256) image. newI = mdilate(Image,Se,Ap,Method) performs dilation on the image Image, using the binary structuring element Se. Se is a matrix containing only 1's and 0's. Ap is the active pointpoint in the Se Matrix, which define the point to dilate. Method is a string that can have one of these values:
 
'binary' - processes the binary image
'gray' - processes the gray image

mErode Perform erosion on binary(2) or gray(256) image. newI = merode(Image,Se,Ap,Method) performs erosion on the image Image, using the binary structuring element Se. Se is a matrix containing only 1's and 0's. Ap is the active point in the Se Matrix, which define the point to erode. Method is a string that can have one of these values:
 
'binary' - processes the binary image
'gray' - processes the gray image

MATLAB release MATLAB 5.2 (R10)
Tags for This File   Please login to tag files.
Please login to add a comment or rating.
Comments and Ratings (2)
23 Jan 2009 Andr?

The core of the merode algorithm should be:
if( Se(m,n)~=0 && tmp1>0 && tmp2>0 && tmp1<=Isize(1,1) && tmp2<=Isize(1,2) )
if (Image(tmp1,tmp2)~= 1)

otherwise any erosion-kernel with zeros in it will erode away everything but exact copies of the kernel.

07 Dec 2004 Markus Karlsson

Four nested for-loops don't provide an efficient algorithm, sorry.

Contact us