Package: vision
Find lines in images via Hough transform
Note:
The 
The HoughTransform
object finds lines in images
via Hough transform. The Hough transform maps points in the Cartesian
image space to curves in the Hough parameter space using the following
equation:
$$rho=x*\mathrm{cos}(theta)+y*\mathrm{sin}(theta)$$
Here, $$rho$$ denotes the distance from the origin to the line along a vector perpendicular to the line, and $$theta$$ denotes the angle between the xaxis and this vector. This object computes the parameter space matrix, whose rows and columns correspond to the rho and theta values respectively. Peak values in this matrix represent potential straight lines in the input image.
Note:
Starting in R2016b, instead of using the 
H = vision.HoughTransform
returns
a Hough transform System object, H
, that implements
the Hough transform to detect lines in images.
H = vision.HoughTransform(
returns
a Hough transform object, Name
,Value
)H
, with each specified
property set to the specified value. You can specify additional namevalue
pair arguments in any order as (Name1
, Value1
,...,NameN
,ValueN
).
H = vision.HoughTransform(THETARES,
RHORES,
returns
a Hough transform object, 'Name'
,Value
,...)H
, with the ThetaResolution
property
set to THETARES
, the RhoResolution
property
set to RHORES
, and other specified properties set
to the specified values.
Code Generation Support 

Supports MATLAB^{®} Function block: Yes 
System Objects in MATLAB Code Generation. 
Code Generation Support, Usage Notes, and Limitations. 

Theta resolution in radians Specify the spacing of the Hough transform bins along the thetaaxis
in radians, as a scalar numeric value between 

Rho resolution Specify the spacing of the Hough transform bins along the rhoaxis
as a scalar numeric value greater than 

Enable theta and rho outputs Set this property to 

Data type of output Specify the data type of the output signal as 
clone  Create Hough transform object with same property values 
getNumInputs  Number of expected inputs to step method 
getNumOutputs  Number of outputs from step method 
isLocked  Locked status for input attributes and nontunable properties 
release  Allow property value and input characteristics changes 
step  Output parameter space matrix for binary input image matrix 
This object implements the algorithm, inputs, and outputs described on the Hough Transform block reference page. The object properties correspond to the block parameters.