How do I know what values to set for the blockSize and constant parameters of adaptiveThreshold().
I am trying to find the contours of an image using the findContours()
method. Firstly, I converted the image to grayscale, and then made it binary using the adaptiveThreshold()
method. How do I know what values to set for the blockSize and constant?
Thanks.
It is not possible to set these values without writting your own algoithm
What do you mean? Thanks.
If my memory is good adaptive threshold uses block image mean to find threshold. When you have two mode in this block threshold found is good but when there is one mode threshold is bad. Problem opencv does not give mean modes values and hence you don't know tjreshold quality