The OpenVX Specification  r28647
 All Data Structures Functions Variables Typedefs Enumerations Enumerator Groups Pages
Object: Array (Advanced)

Detailed Description

Defines the advanced features of the Array Interface.


vx_enum vxRegisterUserStruct (vx_context context, vx_size size)
 Registers user-defined structures to the context. More...

Function Documentation

vx_enum vxRegisterUserStruct ( vx_context  context,
vx_size  size 

Registers user-defined structures to the context.

[in]contextThe reference to the implementation context.
[in]sizeThe size of user struct in bytes.
A vx_enum value that is a type given to the User to refer to their custom structure when declaring a vx_array of that structure.
Return values
VX_TYPE_INVALIDIf the namespace of types has been exhausted.
This call should only be used once within the lifetime of a context for a specific structure.
typedef struct _mystruct {
vx_uint32 some_uint;
vx_float64 some_double;
} mystruct;
#define MY_NUM_ITEMS (10)
vx_enum mytype = vxRegisterUserStruct(context, sizeof(mystruct));
vx_array array = vxCreateArray(context, mytype, MY_NUM_ITEMS);