Functions
VXLIB_fastCorners_i8u

Functions

VXLIB_STATUS VXLIB_fastCorners_i8u (const uint8_t src[], const VXLIB_bufParams2D_t *src_addr, uint32_t corners[], uint8_t strengths[], uint32_t corners_capacity, uint8_t strength_thresh, uint32_t *num_corners, uint8_t do_nonmax, uint8_t scratch[], uint32_t scratch_size)
 
VXLIB_STATUS VXLIB_fastCorners_i8u_checkParams (const uint8_t src[], const VXLIB_bufParams2D_t *src_addr, const uint32_t corners[], const uint8_t strengths[], uint32_t corners_capacity, uint8_t strength_thresh, const uint32_t *num_corners, uint8_t do_nonmax, const uint8_t scratch[], uint32_t scratch_size)
 

Detailed Description

Function Documentation

◆ VXLIB_fastCorners_i8u()

VXLIB_STATUS VXLIB_fastCorners_i8u ( const uint8_t  src[],
const VXLIB_bufParams2D_t *  src_addr,
uint32_t  corners[],
uint8_t  strengths[],
uint32_t  corners_capacity,
uint8_t  strength_thresh,
uint32_t *  num_corners,
uint8_t  do_nonmax,
uint8_t  scratch[],
uint32_t  scratch_size 
)
Description:
Computes the corners in an 8 bit image using the FAST9 algorithm.
Method:
FAST9 algorithm, with optional non-maximum suppression.
Parameters
[in]src[]Pointer to array containing input image (UQ8.0)
[in]src_addr[]Pointer to structure containing dimensional information of src
[out]corners[]Pointer to array containing corner keypoint list (UQ32.0)
[out]strengths[]Pointer to array containing strength list corresponding to corners[] (UQ8.0)
[in]corners_capacityNumber of keypoints allocated in the corners buffer.
[in]strength_threshThreshold on difference between intensity of the central pixel and pixels on the Bresenham's circlue of radius 3.
[out]*num_cornersTotal number of corners found in the image.
[in]do_nonmaxFlag to enable (1) or disable (0) nonmax suppression and strength calculation.
[in]scratch[]Pointer to scratch buffer (UQ8.0)
[in]scratch_sizeSize of the scratch buffer (for parameter checking)
Assumptions:
  • I/O buffer pointers are assumed to be not aliased.
  • The minimum image width and height are both 7.
  • Corners can not be detected in the 3 pixels that make up the image border.
  • Each 32-bit word in corners[] array is composed of 2 16-bit half words representing x and y coordinates, such that corners[i] = (y(i) << 16) | x(i);
  • The scratch buffer should be 8 byte aligned.
  • The strengths pointer may be set to NULL if only the feature locations are needed AND do_nonmax is set to 0.
  • If do_nonmax == 0
    • The strengths[] pointer may be set to NULL.
    • If the strengths[] pointer is set to NULL, the scratch buffer size should be at least 64 bytes.
    • If the strengths[] pointer is not set to NULL, the scratch buffer size should be at least 463 bytes.
  • If do_nonmax == 1
    • The strengths[] pointer must not be set to NULL, since strength values are needed to perform the non-maximum suppression.
    • The scratch buffer should be at least MAX(463, (4 * src_addr->dim_x) + num_corners_in + 30) bytes.
Performance Considerations:
  • For best performance, the following parameter settings are recommended:
    • Set widths equal each other and equal to strides (allows processing over whole image in single loop)

◆ VXLIB_fastCorners_i8u_checkParams()

VXLIB_STATUS VXLIB_fastCorners_i8u_checkParams ( const uint8_t  src[],
const VXLIB_bufParams2D_t *  src_addr,
const uint32_t  corners[],
const uint8_t  strengths[],
uint32_t  corners_capacity,
uint8_t  strength_thresh,
const uint32_t *  num_corners,
uint8_t  do_nonmax,
const uint8_t  scratch[],
uint32_t  scratch_size 
)
Description:
Checks the parameters for programming errors for the VXLIB_fastCorners_i8u function.
Method:
The following checks are made:
  • There shall be no NULL pointers (exception: strenghts can be NULL if do_nonmax == 0)
  • The strides of the image shall be equal to or greater than the x dimension
  • The scratch_size shall be checked according to the parameter settings listed in the function description of the VXLIB_fastCorners_i8u function.
Parameters
[in]src[]Pointer to array containing input image (UQ8.0)
[in]src_addr[]Pointer to structure containing dimensional information of src
[out]corners[]Pointer to array containing corner keypoint list (UQ32.0)
[out]strengths[]Pointer to array containing strength list corresponding to corners[] (UQ8.0)
[in]corners_capacityNumber of keypoints allocated in the corners buffer.
[in]strength_threshThreshold on difference between intensity of the central pixel and pixels on the Bresenham's circlue of radius 3.
[out]*num_cornersTotal number of corners found in the image.
[in]do_nonmaxFlag to enable (1) or disable (0) nonmax suppression and strength calculation.
[in]scratch[]Pointer to scratch buffer (UQ8.0)
[in]scratch_sizeSize of the scratch buffer (for parameter checking)

Copyright 2023, Texas Instruments Incorporated