Which OpenCV4Android class does the field/constant CV_FILLED belongs to?

asked 2016-01-13 04:21:45 -0500

Solace gravatar image

What OpenCV4Android class does the field CV_FILLED belong to? I couldn't find out from my Google search.

It is used as the value of the 5th argument to the Imgproc.drawContours() method. From the documentation:

thickness – Thickness of lines the contours are drawn with. If it is negative (for example, thickness=CV_FILLED ), the contour interiors are drawn.

I need to use it but in Android/Java, I can't use it just like that, I need to use the name of the class it belongs to with the dot operator, something like theClass.CV_FILLED. If I try to use just CV_FILLED, compiler complains, "CV_FILLED cannot be resolved to a variable".

edit retag flag offensive close merge delete



try to use Core.FILLED if your OpenCV version is 3.x or you can pass its value -1

sturkmen gravatar imagesturkmen ( 2016-01-13 04:45:57 -0500 )edit