debugged wrong translation to cv::approxDP and cv::arcLength
further opencvisation of the detector
simplified and debugged Refine