The OpenVX Specification  2b213f9
 All Data Structures Functions Variables Typedefs Enumerations Enumerator Groups Pages
Object: Delay

Detailed Description

Defines the Delay Object interface.

A Delay is an opaque object that contains a manually-controlled, temporally-delayed list of objects. A Delay cannot be an output of a kernel. Also, aging of a Delay (see vxAgeDelay) cannot be performed during graph execution. Supported delay object types include:

Typedefs

typedef struct _vx_delay * vx_delay
 The delay object. This is like a ring buffer of objects that is maintained by the OpenVX implementation. More...
 

Enumerations

enum  vx_delay_attribute_e {
  VX_DELAY_TYPE = ((( VX_ID_KHRONOS ) << 20) | ( VX_TYPE_DELAY << 8)) + 0x0,
  VX_DELAY_SLOTS = ((( VX_ID_KHRONOS ) << 20) | ( VX_TYPE_DELAY << 8)) + 0x1
}
 The delay attribute list. More...
 

Functions

vx_status VX_API_CALL vxAgeDelay (vx_delay delay)
 Ages the internal delay ring by one. This means that once this API is called the reference from index 0 will go to index -1 and so forth until \( -count+1 \) is reached. This last object will become 0. Once the delay has been aged, it updates the reference in any associated nodes. Here \( count \) is the number of slots in delay ring. More...
 
vx_delay VX_API_CALL vxCreateDelay (vx_context context, vx_reference exemplar, vx_size slots)
 Creates a Delay object. More...
 
vx_reference VX_API_CALL vxGetReferenceFromDelay (vx_delay delay, vx_int32 index)
 Retrieves a reference from a delay object. More...
 
vx_status VX_API_CALL vxQueryDelay (vx_delay delay, vx_enum attribute, void *ptr, vx_size size)
 Queries a vx_delay object attribute. More...
 
vx_status VX_API_CALL vxReleaseDelay (vx_delay *delay)
 Releases a reference to a delay object. The object may not be garbage collected until its total reference count is zero. More...
 

Typedef Documentation

typedef struct _vx_delay* vx_delay

The delay object. This is like a ring buffer of objects that is maintained by the OpenVX implementation.

See Also
vxCreateDelay

Definition at line 234 of file vx_types.h.

Enumeration Type Documentation

The delay attribute list.

Enumerator
VX_DELAY_TYPE 

The type of reference contained in the delay. Read-only. Use a vx_enum parameter.

VX_DELAY_SLOTS 

The number of items in the delay. Read-only. Use a vx_size parameter.

Definition at line 1303 of file vx_types.h.

Function Documentation

vx_status VX_API_CALL vxQueryDelay ( vx_delay  delay,
vx_enum  attribute,
void *  ptr,
vx_size  size 
)

Queries a vx_delay object attribute.

Parameters
[in]delayA pointer to a delay object.
[in]attributeThe attribute to query. Use a vx_delay_attribute_e enumeration.
[out]ptrThe location at which to store the resulting value.
[in]sizeThe size of the container to which ptr points.
Returns
A vx_status_e enumeration.
vx_status VX_API_CALL vxReleaseDelay ( vx_delay delay)

Releases a reference to a delay object. The object may not be garbage collected until its total reference count is zero.

Parameters
[in]delayThe pointer to the delay to release.
Postcondition
After returning from this function the reference is zeroed.
Returns
A vx_status_e enumeration.
Return values
VX_SUCCESSNo errors.
VX_ERROR_INVALID_REFERENCEIf delay is not a vx_delay.
vx_delay VX_API_CALL vxCreateDelay ( vx_context  context,
vx_reference  exemplar,
vx_size  slots 
)

Creates a Delay object.

This function uses a subset of the attributes defining the metadata of the exemplar, ignoring the object. It does not alter the exemplar or keep or release the reference to the exemplar. For the definition of supported attributes see vxSetMetaFormatAttribute.

Parameters
[in]contextThe reference to the system context.
[in]exemplarThe exemplar object.Supported delay object types include:
[in]slotsThe number of reference in the delay.
Returns
A delay reference vx_delay. Any possible errors preventing a successful creation should be checked using vxGetStatus.
vx_reference VX_API_CALL vxGetReferenceFromDelay ( vx_delay  delay,
vx_int32  index 
)

Retrieves a reference from a delay object.

Parameters
[in]delayThe reference to the delay object.
[in]indexAn index into the delay from which to extract the reference.
Returns
vx_reference. Any possible errors preventing a successful creation should be checked using vxGetStatus.
Note
The delay index is in the range \( [-count+1,0] \). 0 is always the current object.
A reference from a delay object must not be given to its associated release API (e.g. vxReleaseImage) unless vxRetainReference is used.
vx_status VX_API_CALL vxAgeDelay ( vx_delay  delay)

Ages the internal delay ring by one. This means that once this API is called the reference from index 0 will go to index -1 and so forth until \( -count+1 \) is reached. This last object will become 0. Once the delay has been aged, it updates the reference in any associated nodes. Here \( count \) is the number of slots in delay ring.

Parameters
[in]delay
Returns
A vx_status_e enumeration.
Return values
VX_SUCCESSDelay was aged.
VX_ERROR_INVALID_REFERENCEThe value passed as delay was not a vx_delay.