Filter löschen
Filter löschen

how to calculate the area of certain portion of an image ?

4 Ansichten (letzte 30 Tage)
ajay
ajay am 2 Jan. 2014
Kommentiert: Image Analyst am 4 Jan. 2014
how to calculate the area of certain portion of an image ?

Akzeptierte Antwort

Image Analyst
Image Analyst am 2 Jan. 2014
Bearbeitet: Image Analyst am 2 Jan. 2014
Call regionprops(). See my Image Segmentation Tutorial. It goes over all of that:
For example with a simple thresholding:
binaryImage = grayImage > 90;
measurements = regionprops(binaryImage, 'Area');
allAreas = [measurements.Area];
  2 Kommentare
ajay
ajay am 4 Jan. 2014
its ok but i want the area of particular area
Image Analyst
Image Analyst am 4 Jan. 2014
Then just get it. For example to get the area of blob #42, do this
blob42area = allAreas(42);
blob42area = measurements(42).Area; % Same thing as above.

Melden Sie sich an, um zu kommentieren.

Weitere Antworten (0)

Kategorien

Mehr zu Geometric Transformation and Image Registration 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