Tuesday, July 28, 2009

Activity 8. Morphological Operations

Images containing different shapes were created using the Microsoft Paint. Using Scilab, the images were processed using different structural elements. The created images were a 50x50px square, a circle with 25px radius, a triangle with height equal to 30px and base equal to 50px, a 60x60px hollow square with 4px thick edges, and a plus sign with thickness equal to 8px and line length equal to 50px. The structural elements used are matrices with 4x4 ones, 2x4 ones, 4x2 ones and a cross 5px long and 1px thick. The created images are shown below. The images were processed using the erode and dilate function in Scilab. The outcome or appearance of the images after undergoing erode and dilate were first predicted before using Scilab. The following images were generated using dilate and 4x4, 2x4, 4x2 and cross structuring element, respectively. The first images in each set are the original images followed by the images generated using the structuring elements following the order stated above.


A. Square




B. Triangle




C. Circle



D. Hollow Square


E. Plus

Using Erode and 4x4, 2x4, 4x2 and cross structuring elements, the following images were generated. Each set of images follow the same order as the images above.

A. Square




B. Triangle




C. Circle



D. Hollow Square



E. Plus




The shape of the generated images are the same as the predicted images. The shapes' sizes agree with the predictions with only a small deviation.



1 comment: