Vision Apps User Guide

Introduction

This section documents the kernels defined for Surroundview processing.

Data Structures

struct  LensDistortionCorrection
 The configuration data structure for representing lens model of a signle camera. More...
 
struct  svPointDetect_t
 The point detect structure is the configuration data structure used by the TIVX_KERNEL_POINT_DETECT kernel. More...
 
struct  svLdcLut_t
 The svLdcLut_t structure is the configuration data structure for lens model used by the followig kernel(s) TIVX_KERNEL_POINT_DETECT, TIVX_KERNEL_POSE_ESTIMATION, TIVX_KERNEL_GENERATE_GPULUT. More...
 
struct  svACDetectStructFinalCorner_t
 The svACDetectStructFinalCorner_t structure is the configuration data structure containing detected point coordinates used by the followig kernel(s) TIVX_KERNEL_POINT_DETECT, TIVX_KERNEL_POSE_ESTIMATION. More...
 
struct  svPoseEstimation_t
 The svPoseEstimation_t structure is the configuration data structure used by the TIVX_KERNEL_POSE_ESTIMATION kernel. More...
 
struct  svACCalmatStruct_t
 The svACCalmatStruct_t structure is the structure containing calibration data used by the following kernel(s) TIVX_KERNEL_POSE_ESTIMATION, TIVX_KERNEL_GENERATE_3DBOWL, TIVX_KERNEL_GENERATE_GPULUT. More...
 
struct  svGeometric_t
 The svGeometric_t structure is the configuration data structure used by the TIVX_KERNEL_GENERATE_3DBOWL kernel. More...
 
struct  svGpuLutGen_t
 The svGpuLutGen_t structure is the configuration structure used by the following kernel(s) TIVX_KERNEL_GENERATE_3DBOWL, TIVX_KERNEL_GENERATE_GPULUT. More...
 
struct  tivx_srv_params_t
 The data structure used by the SGX SRV kernel for SRV creation. More...
 

Functions

void tivxSrvLoadKernels (vx_context context)
 Used for the Application to load the srv kernels into the context. More...
 
void tivxSrvUnLoadKernels (vx_context context)
 Used for the Application to unload the srv kernels from the context. More...
 
void tivxSrvPrintPerformance (vx_perf_t performance, uint32_t numPixels, const char *testName)
 Used to print the performance of the kernels. More...
 
void tivxRegisterSrvTargetC66Kernels (void)
 Function to register SRV Kernels on the c66 Target. More...
 
void tivxUnRegisterSrvTargetC66Kernels (void)
 Function to un-register SRV Kernels on the c66 Target. More...
 
void tivxRegisterSrvTargetGpuKernels (void)
 Function to register SRV Kernels on the gpu Target. More...
 
void tivxUnRegisterSrvTargetGpuKernels (void)
 Function to un-register SRV Kernels on the gpu Target. More...
 
VX_API_ENTRY vx_node VX_API_CALL tivxPointDetectNode (vx_graph graph, vx_user_data_object in_configuration, vx_user_data_object in_ldclut, vx_image in, vx_user_data_object out_configuration, vx_image buf_bwluma_frame)
 Creates a POINT_DETECT Node. More...
 
VX_API_ENTRY vx_node VX_API_CALL tivxPoseEstimationNode (vx_graph graph, vx_user_data_object in_configuration, vx_user_data_object in_ldclut, vx_object_array in_corner_points, vx_user_data_object out_calmat)
 Creates a POSE_ESTIMATION Node. More...
 
VX_API_ENTRY vx_node VX_API_CALL tivxGenerate3DbowlNode (vx_graph graph, vx_user_data_object in_configuration, vx_user_data_object in_calmat, vx_user_data_object in_offset, vx_array out_lut3dxyz, vx_user_data_object out_calmat_scaled)
 Creates a GENERATE_3DBOWL Node. More...
 
VX_API_ENTRY vx_node VX_API_CALL tivxGenerateGpulutNode (vx_graph graph, vx_user_data_object in_configuration, vx_user_data_object in_ldclut, vx_user_data_object in_calmat_scaled, vx_array in_lut3dxyz, vx_array out_gpulut3d)
 Creates a GENERATE_GPULUT Node. More...
 
VX_API_ENTRY vx_node VX_API_CALL tivxGlSrvNode (vx_graph graph, vx_user_data_object configuration, vx_object_array input, vx_object_array srv_views, vx_array galign_lut, vx_image output)
 [Graph] Creates a GL_SRV Node. More...
 

Macros

#define TIVX_MODULE_NAME_SRV   "srv"
 Name for OpenVX Extension kernel module: srv. More...
 
#define TIVX_KERNEL_POSE_ESTIMATION_NAME   "com.ti.srv.pose_estimation"
 The list of kernels supported in srv module. More...
 
#define TIVX_KERNEL_POINT_DETECT_NAME   "com.ti.srv.point_detect"
 point_detect kernel name More...
 
#define TIVX_KERNEL_GENERATE_3DBOWL_NAME   "com.ti.srv.generate_3dbowl"
 generate_3dbowl kernel name More...
 
#define TIVX_KERNEL_GENERATE_GPULUT_NAME   "com.ti.srv.generate_gpulut"
 generate_gpulut kernel name More...
 
#define TIVX_KERNEL_GL_SRV_NAME   "com.ti.srv.gl_srv"
 gl_srv kernel name More...
 

Macro Definition Documentation

◆ TIVX_MODULE_NAME_SRV

#define TIVX_MODULE_NAME_SRV   "srv"

Name for OpenVX Extension kernel module: srv.

◆ TIVX_KERNEL_POSE_ESTIMATION_NAME

#define TIVX_KERNEL_POSE_ESTIMATION_NAME   "com.ti.srv.pose_estimation"

The list of kernels supported in srv module.

Each kernel listed here can be used with the vxGetKernelByName call. When programming the parameters, use

  • VX_INPUT for [in]
  • VX_OUTPUT for [out]
  • VX_BIDIRECTIONAL for [in,out]

When programming the parameters, use

  • VX_TYPE_IMAGE for a vx_image in the size field of vxGetParameterByIndex or vxSetParameterByIndex
  • VX_TYPE_ARRAY for a vx_array in the size field of vxGetParameterByIndex or vxSetParameterByIndex
  • or other appropriate types in vx_type_e.

pose_estimation kernel name

◆ TIVX_KERNEL_POINT_DETECT_NAME

#define TIVX_KERNEL_POINT_DETECT_NAME   "com.ti.srv.point_detect"

point_detect kernel name

◆ TIVX_KERNEL_GENERATE_3DBOWL_NAME

#define TIVX_KERNEL_GENERATE_3DBOWL_NAME   "com.ti.srv.generate_3dbowl"

generate_3dbowl kernel name

◆ TIVX_KERNEL_GENERATE_GPULUT_NAME

#define TIVX_KERNEL_GENERATE_GPULUT_NAME   "com.ti.srv.generate_gpulut"

generate_gpulut kernel name

◆ TIVX_KERNEL_GL_SRV_NAME

#define TIVX_KERNEL_GL_SRV_NAME   "com.ti.srv.gl_srv"

gl_srv kernel name

Function Documentation

◆ tivxSrvLoadKernels()

void tivxSrvLoadKernels ( vx_context  context)

Used for the Application to load the srv kernels into the context.

◆ tivxSrvUnLoadKernels()

void tivxSrvUnLoadKernels ( vx_context  context)

Used for the Application to unload the srv kernels from the context.

◆ tivxSrvPrintPerformance()

void tivxSrvPrintPerformance ( vx_perf_t  performance,
uint32_t  numPixels,
const char *  testName 
)

Used to print the performance of the kernels.

◆ tivxRegisterSrvTargetC66Kernels()

void tivxRegisterSrvTargetC66Kernels ( void  )

Function to register SRV Kernels on the c66 Target.

◆ tivxUnRegisterSrvTargetC66Kernels()

void tivxUnRegisterSrvTargetC66Kernels ( void  )

Function to un-register SRV Kernels on the c66 Target.

◆ tivxRegisterSrvTargetGpuKernels()

void tivxRegisterSrvTargetGpuKernels ( void  )

Function to register SRV Kernels on the gpu Target.

◆ tivxUnRegisterSrvTargetGpuKernels()

void tivxUnRegisterSrvTargetGpuKernels ( void  )

Function to un-register SRV Kernels on the gpu Target.

◆ tivxPointDetectNode()

VX_API_ENTRY vx_node VX_API_CALL tivxPointDetectNode ( vx_graph  graph,
vx_user_data_object  in_configuration,
vx_user_data_object  in_ldclut,
vx_image  in,
vx_user_data_object  out_configuration,
vx_image  buf_bwluma_frame 
)

Creates a POINT_DETECT Node.

The node is the first stage of camera calibration and takes in a luma image of a calibration chart. The node detects the position of the 4 corners in each of the two regions of the chart and returns their coordinates. As such it returns 8
entries (4 corners x 2 for x & y coordinates) per ROI for a total of 2 ROIs

Parameters
[in]graphThe reference to the graph.
[in]in_configurationThe input object of a single params structure of the type svPointDetect_t
[in]in_ldclutThe input object of a single params structure of the type svLdcLut_t. Contanins lens parameters of all 4 cameras
[in]inthe input image in VX_DF_IMAGE_U8 format. Only Luma plane of the image is used
[out]out_configurationThe computed output configuration, an object of a single params structure of the type svACDetectStructFinalCorner_t
[out]buf_bwluma_frame(optional) Output image in VX_DF_IMAGE_U8 format.
See also
TIVX_KERNEL_POINT_DETECT_NAME
Returns
vx_node.
Return values
vx_nodeA node reference. Any possible errors preventing a successful creation should be checked using vxGetStatus

◆ tivxPoseEstimationNode()

VX_API_ENTRY vx_node VX_API_CALL tivxPoseEstimationNode ( vx_graph  graph,
vx_user_data_object  in_configuration,
vx_user_data_object  in_ldclut,
vx_object_array  in_corner_points,
vx_user_data_object  out_calmat 
)

Creates a POSE_ESTIMATION Node.

The node is used for generating the pose of each of the cameras in the system. The node uses the information of real world points based on the calibration chart pattern and their projection on the screen and solves a set of linear equations to determine the extrinsic pose of the camera(s)

Parameters
[in]graphThe reference to the graph.
[in]in_configurationThe input object of a single params structure of the type svPoseEstimation_t
[in]in_ldclutThe input object of a single params structure of the type svLdcLut_t. Contains lens parameters of all 4 cameras
[in]in_corner_pointsArray of objects of a single params structure of the type svACDetectStructFinalCorner_t
[out]out_calmatThe Pose of the camera(s), an object of a single params structure of the type svACCalmatStruct_t
See also
TIVX_KERNEL_POSE_ESTIMATION_NAME
Returns
vx_node.
Return values
vx_nodeA node reference. Any possible errors preventing a successful creation should be checked using vxGetStatus

◆ tivxGenerate3DbowlNode()

VX_API_ENTRY vx_node VX_API_CALL tivxGenerate3DbowlNode ( vx_graph  graph,
vx_user_data_object  in_configuration,
vx_user_data_object  in_calmat,
vx_user_data_object  in_offset,
vx_array  out_lut3dxyz,
vx_user_data_object  out_calmat_scaled 
)

Creates a GENERATE_3DBOWL Node.

The node creates a bowl surface for geometric transformations. The existing bowl is a rectiniliear surface with elevated planes with non linear surace at the intersection of planes.

Parameters
[in]graphThe reference to the graph.
[in]in_configurationThe input object of a single params structure of the type svGpuLutGen_t
[in]in_calmatThe input object of a single params structure of the type svACCalmatStruct_t
[in]in_offsetThe input object of a single params structure of the type svGeometric_t
[out]out_lut3dxyzOutput Array of type VX_TYPE_FLOAT32
[out]out_calmat_scaledThe output object of a single params structure of the type svACCalmatStruct_t
See also
TIVX_KERNEL_GENERATE_3DBOWL_NAME
Returns
vx_node.
Return values
vx_nodeA node reference. Any possible errors preventing a successful creation should be checked using vxGetStatus

◆ tivxGenerateGpulutNode()

VX_API_ENTRY vx_node VX_API_CALL tivxGenerateGpulutNode ( vx_graph  graph,
vx_user_data_object  in_configuration,
vx_user_data_object  in_ldclut,
vx_user_data_object  in_calmat_scaled,
vx_array  in_lut3dxyz,
vx_array  out_gpulut3d 
)

Creates a GENERATE_GPULUT Node.

The node performs the bowl surface to the physical camera mapping which is used by the GPU for geometric transformations and for rendering the surroundview output.

Parameters
[in]graphThe reference to the graph.
[in]in_configurationin_configuration The input object of a single params structure of the type svGpuLutGen_t
[in]in_ldclutThe input object of a single params structure of the type svLdcLut_t. Contanins lens parameters of all 4 cameras
[in]in_calmat_scaledThe input object of a single params structure of the type svACCalmatStruct_t
[in]in_lut3dxyzInput Array of type VX_TYPE_FLOAT32
[out]out_gpulut3dOutput Array of type VX_TYPE_UINT16
See also
TIVX_KERNEL_GENERATE_GPULUT_NAME
Returns
vx_node.
Return values
vx_nodeA node reference. Any possible errors preventing a successful creation should be checked using vxGetStatus

◆ tivxGlSrvNode()

VX_API_ENTRY vx_node VX_API_CALL tivxGlSrvNode ( vx_graph  graph,
vx_user_data_object  configuration,
vx_object_array  input,
vx_object_array  srv_views,
vx_array  galign_lut,
vx_image  output 
)

[Graph] Creates a GL_SRV Node.

The node integrates OpenGL calls to render a SRV image from four input images.

Parameters
[in]graphThe reference to the graph.
[in]configurationAn input object of type tivx_srv_params_t used to configure OpenGL SRV
[in]inputAn object array of input images from a capture source which are used by OpenGL SRV
[in]srv_views(optional) An array objects of type srv_coords_t used to define the SRV view
[in]galign_lut(optional) A LUT used for geometric alignment. If not given, the node creates a default LUT
[out]outputAn output SRV image created by OpenGL
See also
TIVX_KERNEL_GL_SRV_NAME
Returns
vx_node.
Return values
vx_nodeA node reference. Any possible errors preventing a successful creation should be checked using vxGetStatus