How can I define two tones in a grayscale image

2 ビュー (過去 30 日間)
Stelios Fanourakis
Stelios Fanourakis 2019 年 5 月 12 日
コメント済み: Jan 2019 年 5 月 19 日
Hi
I have an ultrasound image with lots of gray tones. I want to threshold the image by defining two of its tones. The higher intensity (white tone) and the lowest intensity (darkest gray tone). All other tones in the middle should be eliminated.
How can I do this?
Thanks

採用された回答

Jan
Jan 2019 年 5 月 17 日
編集済み: Jan 2019 年 5 月 19 日
You cannot eliminate colors in a gray-scale image, but only set them to another value.
img(img > 67 & img < 128) = 0;
Here all gray scale values between 68 and 127 are set to 0.
  3 件のコメント
Stelios Fanourakis
Stelios Fanourakis 2019 年 5 月 19 日
"Here all gray scale values between 64 and 127 are set to 0."
You mean values between 68 and 127 are set to 0
Jan
Jan 2019 年 5 月 19 日
@Stelios: Correct. This was a typo.

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

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeUltrasound Imaging についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by