![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/321793/image.png)
How to Threshold Crop an Image for analysis
2 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Brian Peoples
le 24 Juin 2020
Commenté : Brian Peoples
le 26 Juin 2020
Basically all I want to do is perform a lighting analysis on the hair itself in the border i set for it (blue tape). Is there a way I can crop this using some sort of color threshhold? the picture setup should be consistant everytime (i dont want to have to bother w imcrop(). Here is the image:
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/321496/image.jpeg)
0 commentaires
Réponse acceptée
darova
le 25 Juin 2020
Maybe simple binarization?
I0 = imread('image.jpeg');
I1 = I0(:,:,3);
I2 = im2bw(I1,graythresh(I1)-0.1);
imshowpair(I0,I2,'montage')
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/321793/image.png)
5 commentaires
Plus de réponses (0)
Voir également
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!