Problem filling a contour

3 ビュー (過去 30 日間)
Matthew Alston
Matthew Alston 2014 年 7 月 14 日
コメント済み: Matthew Alston 2014 年 7 月 14 日
I previously asked a question about how to fill a region of interest in Matlab, and got a response that I should use activecontour to identify the envelope of the region then extract the color channels and add back pure red as a binaryImage to fill the ROI. I've been trying to do this but keep running into an error message:
"Undefined function or variable 'binaryImage'."
Do I need to convert to binaryImage, and if so how do I do that?
My code and the input image are attached, any help would be greatly appreciated.

採用された回答

Image Analyst
Image Analyst 2014 年 7 月 14 日
It look like what you call binaryImage is what you previously called "mask" in the code. Change it to say mask and it should work better.
  2 件のコメント
Matthew Alston
Matthew Alston 2014 年 7 月 14 日
Ah okay that works perfectly, thanks so much for your help!
Matthew Alston
Matthew Alston 2014 年 7 月 14 日
Being pretty familiar with my project, what method would you recommend to analyze the final filled image? The information I need is: How many red-shaded pixels there are, and what percentage of the pixels within the body outline are shaded red. Any help would be much appreciated.

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

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeImage Data Workflows についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by