63 #ifndef TIVX_KERNELS_TARGET_UTILS_ 64 #define TIVX_KERNELS_TARGET_UTILS_ 66 #include <ti/vxlib/src/common/VXLIB_bufParams.h> 67 #include <tivx_kernels_common_utils.h> 74 #define MAX2(a, b) (((a) > (b)) ? (a) : (b)) 75 #define MAX3(a, b, c) (MAX2((MAX2((a), (b))), (c))) 76 #define MAX4(a, b, c, d) (MAX2((MAX3((a), (b), (c))), (d))) 77 #define MAX5(a, b, c, d, e) (MAX2((MAX4((a), (b), (c), (d))), (e))) 78 #define MAX6(a, b, c, d, e, f) (MAX2((MAX5((a), (b), (c), (d), (e))), (f))) 79 #define MAX7(a, b, c, d, e, f, g) (MAX2((MAX6((a), (b), (c), (d), (e), (f))), (g))) 80 #define MAX8(a, b, c, d, e, f, g, h) (MAX2((MAX7((a), (b), (c), (d), (e), (f), (g))), (h))) 81 #define MAX9(a, b, c, d, e, f, g, h, i) (MAX2((MAX8((a), (b), (c), (d), (e), (f), (g), (h))), (i))) 82 #define MAX10(a, b, c, d, e, f, g, h, i, j) (MAX2((MAX9((a), (b), (c), (d), (e), (f), (g), (h), (i))), (j))) 84 typedef void (*tivxTargetKernel_Fxn) (void);
87 tivxTargetKernel_Fxn add_kernel;
88 tivxTargetKernel_Fxn remove_kernel;
89 } Tivx_Target_Kernel_List;
129 uint16_t max_params);
155 VXLIB_bufParams2D_t buf_params[]);
167 VXLIB_bufParams2D_t buf_params0[],
168 VXLIB_bufParams2D_t buf_params1[]);
254 if (num_params != max_params)
260 for (i = 0U; i < max_params; i ++)
262 if (NULL == obj_desc[i])
Image object descriptor as placed in shared memory.
void tivxRegisterTargetKernels(const Tivx_Target_Kernel_List *kernel_list, uint32_t num_kernels)
Registers the kernels list on the target side.
void tivxUnRegisterTargetKernels(const Tivx_Target_Kernel_List *kernel_list, uint32_t num_kernels)
Unregisters the kernels list on the target side.
vx_status tivxKernelsTargetUtilsAssignTargetNameDsp(char *target_name)
Function to assign platform-specific DSP target name.
static vx_uint32 tivxComputePatchOffset(vx_uint32 x, vx_uint32 y, const vx_imagepatch_addressing_t *addr)
Computes the patch offset into the image.
void tivxInitTwoBufParams(const tivx_obj_desc_image_t *obj_desc0, const tivx_obj_desc_image_t *obj_desc1, VXLIB_bufParams2D_t buf_params0[], VXLIB_bufParams2D_t buf_params1[])
A utility API to initialize two VXLIB bufparams for a kernel where width and height should be equal...
Interface to object descriptor.
void tivxSetPointerLocation(const tivx_obj_desc_image_t *obj_desc, void *target_ptr[], uint8_t *addr[])
A utility API that sets the pointer to the correct location based on the minimum of the valid rectang...
void tivxSetTwoPointerLocation(const tivx_obj_desc_image_t *obj_desc0, const tivx_obj_desc_image_t *obj_desc1, void *target_ptr0[], void *target_ptr1[], uint8_t *addr0[], uint8_t *addr1[])
A utility API that sets the pointer to the correct location based on the minimum of the valid rectang...
vx_status tivxKernelsTargetUtilsAssignTargetNameMcu(char *target_name)
Function to assign platform-specific MCU target name.
void tivxReserveC66xL2MEM(void)
Reserve L2MEM within C66x for usage with BAM framework.
static vx_status tivxCheckNullParams(tivx_obj_desc_t *obj_desc[], uint16_t num_params, uint16_t max_params)
Check number of parameters and NULL pointers.
void tivxInitBufParams(const tivx_obj_desc_image_t *obj_desc, VXLIB_bufParams2D_t buf_params[])
A utility API to initialize VXLIB buf parameters based on the provided object descriptor.