![]() |
VXLIB User Guide
|
Kernel for adding the input image to the output image. This kernel has no internel implementation. Instead, it calls the VXLIB_add kernel implementation.
Performs addition between the input image and the output image and put the result to the output image. The overflow handling is controlled by an overflow-policy parameter VXLIB_OVERFLOW_POLICY. Use VXLIB_WRAP as the parameter for wrap and VXLIB_SATURATE for saturate. The following datatype combinations are supported:
| Case | Input | Output |
|---|---|---|
| 0 | uint8_t | uint8_t |
| 1 | uint8_t | uint16_t |
| 2 | uint16_t | uint16_t |
dst(x,y) = src(x,y) + dst(x,y)
Data Structures | |
| struct | VXLIB_accumulateImage_InitArgs |
| Structure containing the parameters to initialize the kernel. More... | |
Functions | |
| int32_t | VXLIB_accumulateImage_getHandleSize (VXLIB_accumulateImage_InitArgs *pKerInitArgs) |
| This is a query function to calculate the size of internal handle. More... | |
| VXLIB_STATUS | VXLIB_accumulateImage_init (VXLIB_kernelHandle handle, VXLIB_bufParams2D_t *bufParamsIn, VXLIB_bufParams2D_t *bufParamsOut, const VXLIB_accumulateImage_InitArgs *pKerInitArgs) |
| This function should be called before the VXLIB_accumulateImage_exec function is called. This function takes care of any one-time operations such as setting up the configuration of required hardware resources such as the streaming engine. The results of these operations are stored in the handle. More... | |
| VXLIB_STATUS | VXLIB_accumulateImage_init_checkParams (VXLIB_kernelHandle handle, const VXLIB_bufParams2D_t *bufParamsIn, const VXLIB_bufParams2D_t *bufParamsOut, const VXLIB_accumulateImage_InitArgs *pKerInitArgs) |
| This function checks the validity of the parameters passed to VXLIB_accumulateImage_init function. This function is called with the same parameters as the VXLIB_accumulateImage_init, and this function must be called before the VXLIB_accumulateImage_init is called. More... | |
| VXLIB_STATUS | VXLIB_accumulateImage_exec_checkParams (VXLIB_kernelHandle handle, const void *restrict pIn, const void *restrict pOut) |
| This function checks the validity of the parameters passed to VXLIB_accumulateImage_exec function. This function is called with the same parameters as the VXLIB_accumulateImage_init, and this function must be called before the VXLIB_accumulateImage_init is called. More... | |
| VXLIB_STATUS | VXLIB_accumulateImage_exec (VXLIB_kernelHandle handle, void *restrict pIn, void *restrict pOut) |
| This function is the main kernel compute function. More... | |
| void | VXLIB_accumulateImage_perfEst (VXLIB_kernelHandle handle, size_t *archCycles, size_t *estCycles) |
| int32_t VXLIB_accumulateImage_getHandleSize | ( | VXLIB_accumulateImage_InitArgs * | pKerInitArgs | ) |
This is a query function to calculate the size of internal handle.
| [in] | pKerInitArgs | : Pointer to structure holding init parameters |
Definition at line 53 of file VXLIB_accumulateImage.cpp.
| VXLIB_STATUS VXLIB_accumulateImage_init | ( | VXLIB_kernelHandle | handle, |
| VXLIB_bufParams2D_t * | bufParamsIn, | ||
| VXLIB_bufParams2D_t * | bufParamsOut, | ||
| const VXLIB_accumulateImage_InitArgs * | pKerInitArgs | ||
| ) |
This function should be called before the VXLIB_accumulateImage_exec function is called. This function takes care of any one-time operations such as setting up the configuration of required hardware resources such as the streaming engine. The results of these operations are stored in the handle.
| [in] | handle | : Active handle to the kernel |
| [in] | bufParamsIn | : Pointer to the structure containing dimensional information of input image |
| [out] | bufParamsOut | : Pointer to the structure containing dimensional information of output image |
| [in] | pKerInitArgs | : Pointer to the structure holding init parameters |
Definition at line 142 of file VXLIB_accumulateImage.cpp.
| VXLIB_STATUS VXLIB_accumulateImage_init_checkParams | ( | VXLIB_kernelHandle | handle, |
| const VXLIB_bufParams2D_t * | bufParamsIn, | ||
| const VXLIB_bufParams2D_t * | bufParamsOut, | ||
| const VXLIB_accumulateImage_InitArgs * | pKerInitArgs | ||
| ) |
This function checks the validity of the parameters passed to VXLIB_accumulateImage_init function. This function is called with the same parameters as the VXLIB_accumulateImage_init, and this function must be called before the VXLIB_accumulateImage_init is called.
| [in] | handle | : Active handle to the kernel |
| [in] | bufParamsIn | : Pointer to the structure containing dimensional information of input image |
| [out] | bufParamsOut | : Pointer to the structure containing dimensional information of output image |
| [in] | pKerInitArgs | : Pointer to the structure holding init parameters |
Definition at line 67 of file VXLIB_accumulateImage.cpp.
| VXLIB_STATUS VXLIB_accumulateImage_exec_checkParams | ( | VXLIB_kernelHandle | handle, |
| const void *restrict | pIn, | ||
| const void *restrict | pOut | ||
| ) |
This function checks the validity of the parameters passed to VXLIB_accumulateImage_exec function. This function is called with the same parameters as the VXLIB_accumulateImage_init, and this function must be called before the VXLIB_accumulateImage_init is called.
| [in] | handle | : Active handle to the kernel |
| [in] | pIn | : Pointer to the structure input image |
| [out] | pOut | : Pointer to the output image |
Definition at line 118 of file VXLIB_accumulateImage.cpp.
| VXLIB_STATUS VXLIB_accumulateImage_exec | ( | VXLIB_kernelHandle | handle, |
| void *restrict | pIn, | ||
| void *restrict | pOut | ||
| ) |
This function is the main kernel compute function.
Please refer to details under VXLIB_accumulateImage_exec
| [in] | handle | : Active handle to the kernel |
| [in] | pIn | : Pointer to the structure input image |
| [out] | pOut | : Pointer to the output image |
Definition at line 223 of file VXLIB_accumulateImage.cpp.
| void VXLIB_accumulateImage_perfEst | ( | VXLIB_kernelHandle | handle, |
| size_t * | archCycles, | ||
| size_t * | estCycles | ||
| ) |
Definition at line 238 of file VXLIB_accumulateImage.cpp.