hi_mpi_vpc_set_chn_workspace
Applicability
Product |
Supported |
|---|---|
√ |
|
√ |
|
√ |
|
☓ |
|
☓ |
Description
This API is called to allocate a temporary buffer. For each channel, this API can be set only once and cannot be modified later.
Due to hardware restrictions, you need to call this API to allocate a temporary buffer required for storing task process data when you execute a remapping or affine transformation task. When this API is called, the system allocates an internal temporary buffer based on the maximum width and height of the input and output images. The allocated buffer is automatically released when the channel is destroyed.
Prototype
hi_s32 hi_mpi_vpc_set_chn_workspace (hi_vpc_chn chn, hi_vpc_workspace_param *workspace_param, hi_u32 param_cnt)
Parameters
Parameter |
Input/Output |
Description |
|---|---|---|
chn |
Input |
Channel ID for image processing. |
workspace_param |
Input |
Pointer to the workspace_param array. The value of hi_vpc_workspace_param.func needs to be set based on the used remapping or affine transformation function. If the remapping and affine transformation functions both are involved in an application, the workspace_param array can contain two elements. Set hi_vpc_workspace_param.func of the elements to REMAP and AFFINE, respectively. |
param_cnt |
Input |
Array length, which must be the same as the length of the workspace_param array. |
Returns
- 0: success
- Other values: failure (VPC Return Codes)