Object for storing SURF interest points
This object provides the ability to pass data between the detectSURFFeatures and extractFeatures functions. It can also be used to manipulate and plot the data returned by these functions. You can use the object to fill the points interactively. You can use this approach in situations where you might want to mix a non-SURF interest point detector with a SURF descriptor.
Although SURFPoints may hold many points, it is a scalar object. Therefore, NUMEL(surfPoints) always returns 1. This value may differ from LENGTH(surfPoints), which returns the true number of points held by the object.
points = SURFPoints(Location) constructs a SURFPoints object from an M-by-2 array of [x y] point coordinates, Location.
points = SURFPoints(Location,Name,Value) constructs a SURFPoints object with optional input properties specified by one or more Name,Value pair arguments. Each additional property can be specified as a scalar or a vector whose length matches the number of coordinates in Location.
M-by-2 array of [x y] point coordinates.
Number of points held by the object.
Specifies scale at which the interest points were detected. This value must be greater than or equal to 1.6.
Value describing strength of detected feature. The SURF algorithm uses a determinant of an approximated Hessian.
Sign of the Laplacian determined during the detection process. This value must be an integer, -1, 0, or 1. You can use this parameter to accelerate the feature matching process.
Blobs with identical metric values but different signs of Laplacian can differ by their intensity values. For example, a white blob on a blackground versus a black blob on a white background. You can use this parameter to quickly eliminate blobs that do not match.
For non-SURF detectors, this property is not relevant. For example, for corner features, you can simply use the default value of 0.
Describes the orientation of the detected feature. This value must be specified as an angle, in radians. The angle is measured from the X-axis with the origin at the point given by the Location property. Typically, this value gets set during the descriptor extraction process. The extractFeatures function modifies the default value of 0. Do not set this property manually. Rely instead on the call to extractFeatures to fill in this value. The Orientation is mainly useful for visualization purposes.
|isempty||Returns true for empty object|
|length||Number of stored points|
|plot||Plot SURF points|
|selectStrongest||Return points with strongest metrics|
|size||Size of the SURFPoints object|
Detect, store, and display the last 5 SURF points of an image
I = imread('cameraman.tif'); points = detectSURFFeatures(I); Display the last 5 points imshow(I); hold on; plot(points(end-4:end));
Using corner detection, create a SURF points object and then extract SURF descriptors.
Load an image.
I = imread('cameraman.tif');
Construct corner detector System object.
hcornerdet = vision.CornerDetector('Method', 'Local intensity comparison (Rosten & Drummond)');
Invoke the object on image, I.
ptsArray = step(hcornerdet, I);
Transform the array of [x y] coordinates into a SURFPoints object.
ptsObj = SURFPoints; % start with an empty object ptsObj = ptsObj.append(ptsArray, 'Scale', 2);
Extract SURF descriptors and visualize the first 5 descriptors.
[features, validPtsObj] = extractFeatures(I, ptsObj); imshow(I); hold on; plot(validPtsObj(1:5),'showOrientation',true);
 Bradski, G. and A. Kaehler, Learning OpenCV : Computer Vision with the OpenCV Library, O'Reilly, Sebastopol, CA, 2008.
 Matas, J., O. Chum, M. Urba, and T. Pajdla. "Robust wide baseline stereo from maximally stable extremal regions." Proc. of British Machine Vision Conference, pages 384-396, 2002.