Effacer les filtres
Effacer les filtres

How can I define two tones in a grayscale image

1 vue (au cours des 30 derniers jours)
Stelios Fanourakis
Stelios Fanourakis le 12 Mai 2019
Commenté : Jan le 19 Mai 2019
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

Réponse acceptée

Jan
Jan le 17 Mai 2019
Modifié(e) : Jan le 19 Mai 2019
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 commentaires
Stelios Fanourakis
Stelios Fanourakis le 19 Mai 2019
"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 le 19 Mai 2019
@Stelios: Correct. This was a typo.

Connectez-vous pour commenter.

Plus de réponses (0)

Catégories

En savoir plus sur Ultrasound Imaging dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by