Detect corners using FAST algorithm and return
Read the image.
I = imread('cameraman.tif');
Find the corners.
corners = detectFASTFeatures(I);
Display the results.
imshow(I); hold on; plot(corners.selectStrongest(50));
I— Input image
Input image, specified in 2-D grayscale. The input image must be real and nonsparse.
comma-separated pairs of
the argument name and
Value is the corresponding value.
Name must appear inside quotes. You can specify several name and value
pair arguments in any order as
[50,150,100,200]specifies that the detector must use a 1% minimum accepted quality of corners within the designated region of interest. This region of interest is located at
150. The ROI has a width of
100pixels, and a height of
'MinQuality'— Minimum accepted quality of corners
Minimum accepted quality of corners, specified as the comma-separated
pair consisting of '
MinQuality' and a scalar
value in the range [0,1].
The minimum accepted quality of corners represents a fraction of the maximum corner metric value in the image. Larger values can be used to remove erroneous corners.
'MinContrast'— Minimum intensity
Minimum intensity difference between corner and surrounding
region, specified as the comma-separated pair consisting of '
and a scalar value in the range (0,1).
The minimum intensity represents a fraction of the maximum value of the image class. Increasing the value reduces the number of detected corners.
'ROI'— Rectangular region
size(I,1)] (default) | vector
Rectangular region for corner detection, specified as a comma-separated
pair consisting of '
ROI' and a vector of the
format [x y width height].
The first two integer values [x y]
represent the location of the upper-left corner of the region of interest.
The last two integer values represent the width and height.
 Rosten, E., and T. Drummond. "Fusing Points and Lines for High Performance Tracking," Proceedings of the IEEE International Conference on Computer Vision, Vol. 2 (October 2005): pp. 1508–1511.
Usage notes and limitations:
Generates portable C code using a C++ compiler that links to OpenCV (Version 3.4.0) libraries. See Portable C Code Generation for Functions That Use OpenCV Library.
GPU support will be removed in a future release.
This function fully supports GPU arrays. For more information, see Run MATLAB Functions on a GPU (Parallel Computing Toolbox).