Find area from binary image.

Hello,
I have this binary image:
I want to encircle it with ellipse or any kind of boundary like below:
After this, I have to fill the area inside the boundary and want to found out the area of this boundary. How to do so?
Thanks.

 采纳的回答

Try this:
binaryImage = bwconvhull(binaryImage, 'union');
area = bwarea(binaryImage);
% or for a simple sum of pixels:
area = sum(binaryImage(:));

更多回答(1 个)

Naga Sai Anupoju
Naga Sai Anupoju 2019-4-24

1 个投票

binaryImage = bwconvhull(binaryImage, 'union');
area = bwarea(binaryImage);
% or for a simple sum of pixels:
area = sum(binaryImage(:));

2 个评论

??? This answer is identical to the one I posted a year and a half ago.
Use special button for code inserting please
Untitled.png

请先登录,再进行评论。

类别

帮助中心File Exchange 中查找有关 Convert Image Type 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by