Filter löschen
Filter löschen

How to remove unwanted objects of smaller than a certain threshold area from a grayscale image?

6 Ansichten (letzte 30 Tage)
My algorithm is as follows :- - convert entire image to binary form - remove the objects of the area smaller than required. My problem is to how to work on the object of larger area in its gray scale form. Please suggest any other method if better

Antworten (1)

Walter Roberson
Walter Roberson am 12 Mär. 2013
See bwareaopen() but notice that it works on black and white images. So you could convert your grayscale to B&W, run the area open, then use the resulting B&W image as a mask on your grayscale.
  2 Kommentare
Image Analyst
Image Analyst am 12 Mär. 2013
Bearbeitet: Image Analyst am 12 Mär. 2013
To mask (one way of doing it):
grayImage(~binaryImage) = 0; % Set background to zero.
Richa Nayak
Richa Nayak am 13 Mär. 2013
You BlobsDemo Tutorial has been very helpful till now. dint refer to it for this tho. Thanks a lot!

Melden Sie sich an, um zu kommentieren.

Kategorien

Mehr zu Convert Image Type finden Sie in Help Center und File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by