Class CudaHoughSegmentDetector
Base class for line segments detector algorithm.
public class CudaHoughSegmentDetector : SharedPtrObject, IDisposable
- Inheritance
-
CudaHoughSegmentDetector
- Implements
- Inherited Members
Constructors
CudaHoughSegmentDetector(float, float, int, int, int)
Create a hough segment detector
public CudaHoughSegmentDetector(float rho, float theta, int minLineLength, int maxLineGap, int maxLines = 4096)
Parameters
rho
floatDistance resolution of the accumulator in pixels.
theta
floatAngle resolution of the accumulator in radians.
minLineLength
intMinimum line length. Line segments shorter than that are rejected.
maxLineGap
intMaximum allowed gap between points on the same line to link them.
maxLines
intMaximum number of output lines.
Methods
Detect(IInputArray, IOutputArray, Stream)
Finds line segments in a binary image using the probabilistic Hough transform.
public void Detect(IInputArray image, IOutputArray lines, Stream stream = null)
Parameters
image
IInputArray8-bit, single-channel binary source image
lines
IOutputArrayOutput vector of lines. Each line is represented by a 4-element vector (x1, y1, x2, y2) , where (x1, y1) and (x2, y2) are the ending points of each detected line segment.
stream
StreamUse a Stream to call the function asynchronously (non-blocking) or null to call the function synchronously (blocking).
DisposeObject()
Release the unmanaged memory associated with this segment detector
protected override void DisposeObject()