How to convert MatOfPoint to MatOfPoint2f in opencv java api

前端 未结 3 1196
误落风尘
误落风尘 2020-12-07 23:01

I\'m trying to implement the example code of the following question by using opencv java api. To implement findContours(gray, contours, CV_RETR_LIST, CV_CHAIN_APPROX_

3条回答
  •  爱一瞬间的悲伤
    2020-12-07 23:35

    I realise this question has already been well answered, but to add an alternative for anyone who finds it in the future -

    Imgproc.findContours(gray, contours, new Mat(), Imgproc.RETR_LIST, Imgproc.CHAIN_APPROX_SIMPLE);
    
    for(int i=0;i

提交回复
热议问题