Click or drag to resize

Cv2HoughCircles Method

Finds circles in a grayscale image using a Hough transform.

Namespace:  OpenCvSharp
Assembly:  OpenCvSharp (in OpenCvSharp.dll) Version: 1.0.0
Syntax
public static CircleSegment[] HoughCircles(
	InputArray image,
	HoughMethods method,
	double dp,
	double minDist,
	double param1 = 100,
	double param2 = 100,
	int minRadius = 0,
	int maxRadius = 0
)

Parameters

image
Type: OpenCvSharpInputArray
The 8-bit, single-channel, grayscale input image
method
Type: OpenCvSharpHoughMethods
Currently, the only implemented method is HoughCirclesMethod.Gradient
dp
Type: SystemDouble
The inverse ratio of the accumulator resolution to the image resolution.
minDist
Type: SystemDouble
Minimum distance between the centers of the detected circles.
param1 (Optional)
Type: SystemDouble
The first method-specific parameter. [By default this is 100]
param2 (Optional)
Type: SystemDouble
The second method-specific parameter. [By default this is 100]
minRadius (Optional)
Type: SystemInt32
Minimum circle radius. [By default this is 0]
maxRadius (Optional)
Type: SystemInt32
Maximum circle radius. [By default this is 0]

Return Value

Type: CircleSegment
The output vector found circles. Each vector is encoded as 3-element floating-point vector (x, y, radius)
See Also