http://www.emgu.com

Pointer to the sequence of circles

Finds circles in grayscale image using some modification of Hough transform

**Namespace:** Emgu.CV**Assembly:** Emgu.CV (in Emgu.CV.dll) Version: 2.4.10.1935 (2.4.10.1935)

# Syntax

C# |
---|

public static IntPtr cvHoughCircles( IntPtr image, IntPtr circleStorage, HOUGH_TYPE method, double dp, double minDist, double param1, double param2, int minRadius, int maxRadius ) |

Visual Basic |
---|

Public Shared Function cvHoughCircles ( image As IntPtr, circleStorage As IntPtr, method As HOUGH_TYPE, dp As Double, minDist As Double, param1 As Double, param2 As Double, minRadius As Integer, maxRadius As Integer ) As IntPtr |

Visual C++ |
---|

public: static IntPtr cvHoughCircles( IntPtr image, IntPtr circleStorage, HOUGH_TYPE method, double dp, double minDist, double param1, double param2, int minRadius, int maxRadius ) |

F# |
---|

static member cvHoughCircles : image : IntPtr * circleStorage : IntPtr * method : HOUGH_TYPE * dp : float * minDist : float * param1 : float * param2 : float * minRadius : int * maxRadius : int -> IntPtr |

#### Parameters

- image
- Type: System..::..IntPtr

The input 8-bit single-channel grayscale image

- circleStorage
- Type: System..::..IntPtr

The storage for the circles detected. It can be a memory storage (in this case a sequence of circles is created in the storage and returned by the function) or single row/single column matrix (CvMat*) of type CV_32FC3, to which the circles' parameters are written. The matrix header is modified by the function so its cols or rows will contain a number of lines detected. If circle_storage is a matrix and the actual number of lines exceeds the matrix size, the maximum possible number of circles is returned. Every circle is encoded as 3 floating-point numbers: center coordinates (x,y) and the radius

- method
- Type: Emgu.CV.CvEnum..::..HOUGH_TYPE

Currently, the only implemented method is CV_HOUGH_GRADIENT

- dp
- Type: System..::..Double

Resolution of the accumulator used to detect centers of the circles. For example, if it is 1, the accumulator will have the same resolution as the input image, if it is 2 - accumulator will have twice smaller width and height, etc

- minDist
- Type: System..::..Double

Minimum distance between centers of the detected circles. If the parameter is too small, multiple neighbor circles may be falsely detected in addition to a true one. If it is too large, some circles may be missed

- param1
- Type: System..::..Double

The first method-specific parameter. In case of CV_HOUGH_GRADIENT it is the higher threshold of the two passed to Canny edge detector (the lower one will be twice smaller).

- param2
- Type: System..::..Double

The second method-specific parameter. In case of CV_HOUGH_GRADIENT it is accumulator threshold at the center detection stage. The smaller it is, the more false circles may be detected. Circles, corresponding to the larger accumulator values, will be returned first

- minRadius
- Type: System..::..Int32

Minimal radius of the circles to search for

- maxRadius
- Type: System..::..Int32

Maximal radius of the circles to search for. By default the maximal radius is set to max(image_width, image_height).

#### Return Value

Type: IntPtrPointer to the sequence of circles