VPI - Vision Programming Interface

1.0 Release

Harris Corners

Data Structures

struct  VPIHarrisCornerDetectorParams
 Structure that defines the parameters for vpiSubmitHarrisCornerDetector. More...
 

Functions

VPIStatus vpiCreateHarrisCornerDetector (uint32_t backends, int32_t inputWidth, int32_t inputHeight, VPIPayload *payload)
 Creates a Harris Corner Detector payload. More...
 
VPIStatus vpiSubmitHarrisCornerDetector (VPIStream stream, uint32_t backend, VPIPayload payload, VPIImage input, VPIArray outFeatures, VPIArray outScores, const VPIHarrisCornerDetectorParams *params)
 Submits Harris Corner Detector operation to the stream associated with the payload. More...
 

Detailed Description


Data Structure Documentation

◆ VPIHarrisCornerDetectorParams

struct VPIHarrisCornerDetectorParams

Structure that defines the parameters for vpiSubmitHarrisCornerDetector.

Definition at line 79 of file HarrisCorners.h.

+ Collaboration diagram for VPIHarrisCornerDetectorParams:
Data Fields
int32_t blockSize Block window size used to compute the Harris Corner score.

Must be 3, 5 or 7.

int32_t gradientSize Gradient window size.

Must be 3, 5 or 7.

float minNMSDistance Non-maximum suppression radius, set to 0 to disable it.

For PVA backend, this must be set to 8.

float sensitivity Specifies sensitivity threshold from the Harris-Stephens equation.
float strengthThresh Specifies the minimum threshold with which to eliminate Harris Corner scores.

Function Documentation

◆ vpiCreateHarrisCornerDetector()

VPIStatus vpiCreateHarrisCornerDetector ( uint32_t  backends,
int32_t  inputWidth,
int32_t  inputHeight,
VPIPayload payload 
)

#include <vpi/algo/HarrisCorners.h>

Creates a Harris Corner Detector payload.

This function allocates all temporary memory needed by the algorithm.

Parameters
[in]backendsVPI backends that are eligible to execute the algorithm. Currently only one backend is accepted.
[in]inputWidth,inputHeightDimensions of the input image that will be used with this payload.
[out]payloadPointer to memory where the created payload handle will be written to.
Returns
VPI_SUCCESS if payload was created successfully, some other VPIStatus value in case of error.

◆ vpiSubmitHarrisCornerDetector()

VPIStatus vpiSubmitHarrisCornerDetector ( VPIStream  stream,
uint32_t  backend,
VPIPayload  payload,
VPIImage  input,
VPIArray  outFeatures,
VPIArray  outScores,
const VPIHarrisCornerDetectorParams params 
)

#include <vpi/algo/HarrisCorners.h>

Submits Harris Corner Detector operation to the stream associated with the payload.

Parameters
[in]streamThe stream where the operation will be queued in.
[in]backendBackend that will execute the algorithm. Must be one of the backends specified during payload creation. If 0, VPI will select one of the eligible backends from the payload that accepts the given parameters, usually the fastest one.
[in]payloadPayload to be submitted along the other parameters.
[in]inputInput image from where the Harris corners will be extracted.
[out]outFeaturesArray that will receive the detected corners. It must have type VPI_ARRAY_TYPE_KEYPOINT.
[out]outScoresArray that will receive the corners' scores. It must have type VPI_ARRAY_TYPE_U32.
[in]paramsPointer to a VPIHarrisCornerDetectorParams with parameters for this algorithm invocation. These parameters can vary in every call and will be copied internally, no need to keep the object around.
Returns
VPI_SUCCESS if the algorithm submitted was created successfully, some other VPIStatus value in case of error. Even if VPI_SUCCESS is returned, the actual algorithm execution might still fail, due to invalid parameters. The actual error will only be returned by some synchronization call or another algorithm submission.