posted by 심재형 2017. 11. 15. 13:15

minEnclosingCircle

Finds a circle of the minimum area enclosing a 2D point set.

C++: void minEnclosingCircle(InputArray points, Point2f& center, float& radius)
Python: cv2.minEnclosingCircle(points) → center, radius
C: int cvMinEnclosingCircle(const CvArr* points, CvPoint2D32f* center, float* radius)
Python: cv.MinEnclosingCircle(points)-> (int, center, radius)
Parameters:
  • points –

    Input vector of 2D points, stored in:

    • std::vector<> or Mat (C++ interface)
    • CvSeq* or CvMat* (C interface)
    • Nx2 numpy array (Python interface)
  • center – Output center of the circle.
  • radius – Output radius of the circle.

The function finds the minimal enclosing circle of a 2D point set using an iterative algorithm. See the OpenCV sample minarea.cpp .

'OpenCV' 카테고리의 다른 글

matchShapes  (0) 2017.11.15
내부 최소사각형 - minAreaRect  (0) 2017.11.15
적당한 선으로 채우기 fitLine  (0) 2017.11.15
구멍 채우기 - fitEllipse  (0) 2017.11.15
형태 볼록함 결점찾기, 구멍찾기 - convexityDefects  (0) 2017.11.15