Weird result from MorphologyEx
Hi guys,
I am trying to use MorphologyEx to open the white area in ful horizontal way. Please see the image attached. But in the result, the white is not fully opened horizontally.
kernel = np.ones((50,2),np.uint8) cv.morphologyEx(img, cv.MORPH_CLOSE, kernel) //MORPH_OPEN also doesn't give me what I want
What is wrong in my code?
The above code is not my exact code tho. I am using OpenCVSharp now.
My OpenCVSharp code is: Cv.MorphologyEx( image, image, temp, new IplConvKernel( 50, 2, 1, 1, ElementShape.Ellipse ), MorphologyOperation.Close );
Please help!
Can you post a sample image, that's not working. Particularly as a .png, so we can see the exact same pixel values.
I uploaded a sample image and the actual code I used. Please help!