I want to apply convex Hull in MATLAB on gray scale image but regionprop and other built-in functions that are provided on net are not working please help me, to find objects from images that have less connectivity between pixels.
Asked
Active
Viewed 2,767 times
0
-
1Try to edit your post and upload the image. – Cape Code Jan 22 '14 at 19:54
1 Answers
0
First, you need to create a binary image out of your grayscale image. One option is by thresholding:
t=imgraythresh(YourGrayImage);
bw=im2bw(YourGrayImage, t);
Then obtain the convex hull like this:
ConvHull=bwconvhull(bw,'union')
Or, if you want the convex hull of all individual objects:
ConvHull=bwconvhull(bw,'objects')

Cape Code
- 3,584
- 3
- 24
- 45