how to calculate the area of certain portion of an image ?
3 次查看(过去 30 天)
显示 更早的评论
how to calculate the area of certain portion of an image ?
0 个评论
采纳的回答
Image Analyst
2014-1-2
编辑:Image Analyst
2014-1-2
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 个评论
Image Analyst
2014-1-4
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.
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Image Segmentation and Analysis 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!