Package: vision
2D crosscorrelation of two input matrices
The Crosscorrelator
object computes 2D crosscorrelation
of two input matrices.
Note:
Starting in R2016b, instead of using the 
H = vision.Crosscorrelator
returns
a System object, H
, that performs twodimensional
crosscorrelation between two inputs.
H = vision.Crosscorrelator(
returns
a 2D cross correlation System 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
).
Code Generation Support 

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

Specify dimensions of output This property controls the size of the output scalar, vector,
or matrix produced as a result of the crosscorrelation between the
two inputs. This property can be set to one of 

Normalize output Set this property to 
clone  Create 2D cross correlator 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  Compute 2D correlation of input matrices 
Compute the 2D correlation of two matrices.
hcorr2d = vision.Crosscorrelator; x1 = [1 2;2 1]; x2 = [1 1;1 1]; y = step(hcorr2d,x1,x2);
This object implements the algorithm, inputs, and outputs described on the 2D Correlation block reference page. The object properties correspond to the block parameters.