Click or drag to resize
Accord.NET (logo)

HoughCircleTransformation Class

Hough circle transformation.
Inheritance Hierarchy
SystemObject
  Accord.ImagingHoughCircleTransformation

Namespace:  Accord.Imaging
Assembly:  Accord.Imaging (in Accord.Imaging.dll) Version: 3.8.0
Syntax
public class HoughCircleTransformation
Request Example View Source

The HoughCircleTransformation type exposes the following members.

Constructors
  NameDescription
Public methodHoughCircleTransformation
Initializes a new instance of the HoughCircleTransformation class.
Top
Properties
  NameDescription
Public propertyCirclesCount
Found circles count.
Public propertyLocalPeakRadius
Radius for searching local peak value.
Public propertyMaxIntensity
Maximum found intensity in Hough map.
Public propertyMinCircleIntensity
Minimum circle's intensity in Hough map to recognize a circle.
Top
Methods
  NameDescription
Public methodEquals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Protected methodFinalize
Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object.)
Public methodGetCirclesByRelativeIntensity
Get circles with relative intensity higher then specified value.
Public methodGetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public methodGetMostIntensiveCircles
Get specified amount of circles with highest intensity.
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Protected methodMemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Public methodProcessImage(Bitmap)
Process an image building Hough map.
Public methodProcessImage(BitmapData)
Process an image building Hough map.
Public methodProcessImage(UnmanagedImage)
Process an image building Hough map.
Public methodToBitmap
Ñonvert Hough map to bitmap.
Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)
Top
Extension Methods
  NameDescription
Public Extension MethodHasMethod
Checks whether an object implements a method with the given name.
(Defined by ExtensionMethods.)
Public Extension MethodIsEqual
Compares two objects for equality, performing an elementwise comparison if the elements are vectors or matrices.
(Defined by Matrix.)
Public Extension MethodTo(Type)Overloaded.
Converts an object into another type, irrespective of whether the conversion can be done at compile time or not. This can be used to convert generic types to numeric types during runtime.
(Defined by ExtensionMethods.)
Public Extension MethodToTOverloaded.
Converts an object into another type, irrespective of whether the conversion can be done at compile time or not. This can be used to convert generic types to numeric types during runtime.
(Defined by ExtensionMethods.)
Top
Remarks

The class implements Hough circle transformation, which allows to detect circles of specified radius in an image.

The class accepts binary images for processing, which are represented by 8 bpp grayscale images. All black pixels (0 pixel's value) are treated as background, but pixels with different value are treated as circles' pixels.

Sample usage:

HoughCircleTransformation circleTransform = new HoughCircleTransformation( 35 );
// apply Hough circle transform
circleTransform.ProcessImage( sourceImage );
Bitmap houghCirlceImage = circleTransform.ToBitmap( );
// get circles using relative intensity
HoughCircle[] circles = circleTransform.GetCirclesByRelativeIntensity( 0.5 );

foreach ( HoughCircle circle in circles )
{
    // ...
}

Initial image:

Hough circle transformation image:

See Also