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.

 採用された回答

Image Analyst
Image Analyst 2017 年 11 月 1 日

0 投票

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 件のコメント

Image Analyst
Image Analyst 2019 年 4 月 27 日
??? This answer is identical to the one I posted a year and a half ago.
darova
darova 2019 年 4 月 27 日
Use special button for code inserting please
Untitled.png

サインインしてコメントする。

カテゴリ

ヘルプ センター および File ExchangeConvert Image Type についてさらに検索

タグ

質問済み:

2017 年 11 月 1 日

コメント済み:

2019 年 4 月 27 日

Community Treasure Hunt

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

Start Hunting!

Translated by