How to extract 4 portions of main object of image with black background
이전 댓글 표시
Hi,
I have an image with a black background. I would like to extract 4 portions of the main object of the image, a leaf (as I show in the image B.png). I would like to extract 4 portions as matrixes of 100 x 100 pixels. I thought one way to do that it would be to split the leaf in 4 quadrants and then extract 1 portion of each quadrant.
The problem is that I need to do it without considering that black background of the image. So, when extracting those portions of the image, I don't want to get those black pixels too, only parts that are inside the leaf. Is this possible?
I need those portions to do a texture analysis with a Local Binary Pattern code I've developed.
I've attached both images: the original (A.png) and and example of what I need (B.png).
I really appreciate your help. Thank you in advance!


채택된 답변
추가 답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 Agriculture에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
