Back to Aurora Vision Studio website

You are here: Start » Filter Reference » OpenCV » Feature Detection » cvCornerSubPix

cvCornerSubPix


Module: OpenCV

Refines the corner locations.

Name Type Range Description
Input value inImage Image Input image.
Input value inCorners Point2DArray Initial coordinates of the input corners.
Input value inWinWidth Integer 1 - Half of the width of the search window.
Input value inWinHeight Integer 1 - Half of the height of the search window.
Input value inZeroZoneWidth Integer Half of the width of the dead region in the middle of the search zone over which the summation in the formula below is not done.
Input value inZeroZoneHeight Integer Half of the height of the dead region in the middle of the search zone over which the summation in the formula below is not done.
Input value inTcEpsilon Real Criteria for termination of the iterative process of corner refinement. Process stops when either after inTcMaxCount iterations or when the corner position moves by less than inTcEpsilon.
Input value inTcMaxCount Integer Criteria for termination of the iterative process of corner refinement. Process stops when either after inTcMaxCount iterations or when the corner position moves by less than inTcEpsilon.
Input value inTcType CvTerminationCriteria Indicates which termination criteria will be used.
Output value outCorners Point2DArray Refined coordinates of input points.

Description

The operation iterates to find the sub-pixel accurate location of corners or radial saddle points. The actual corners are searched in area of dimensions twice as big as inWinWidth and inWidHeight, centered on the initial corners. The algorithm iterates to the moment when last refinement was smaller than inTcEpsilon or the number of iteration exceeds inTcMaxCount. The stopping condition can be set in inTcType.

Examples

Resulting corners of cvCornersSubPix performed on the sample image with inCorners from the sample image, inWinWidth = 12, inWinHeight = 12, inTcEpsilon = 0, inTcMaxCount = 30 and inTcType = 3, drawn on the sample image.

Errors

This filter can throw an exception to report error. Read how to deal with errors in Error Handling.

List of possible exceptions:

Error type Description
DomainError Corners array must not be empty in cvCornerSubPix.
DomainError Input image must be single-channel UINT8 or REAL in cvCornerSubPix.

Complexity Level

This filter is available on Basic Complexity Level.

See Also