|
VPI - Vision Programming Interface
0.2.0 Release
|
Go to the documentation of this file.
56 #ifndef NV_VPI_ARRAY_H
57 #define NV_VPI_ARRAY_H
103 #define VPI_ARRAY_DISABLE_PVA VPI_BACKEND_DISABLE_PVA
104 #define VPI_ARRAY_DISABLE_CPU VPI_BACKEND_DISABLE_CPU
105 #define VPI_ARRAY_DISABLE_CUDA VPI_BACKEND_DISABLE_CUDA
107 #define VPI_ARRAY_ONLY_PVA VPI_BACKEND_ONLY_PVA
108 #define VPI_ARRAY_ONLY_CPU VPI_BACKEND_ONLY_CPU
109 #define VPI_ARRAY_ONLY_CUDA VPI_BACKEND_ONLY_CUDA
114 #define VPI_ARRAY_NO_PVA VPI_ARRAY_DISABLE_PVA
115 #define VPI_ARRAY_NO_CPU VPI_ARRAY_DISABLE_CPU
116 #define VPI_ARRAY_NO_CUDA VPI_ARRAY_DISABLE_CUDA
120 typedef struct VPIArrayDataRec
279 #endif // NV_VPI_ARRAY_H
void vpiArrayDestroy(VPIArray array)
Destroy an array instance as well as all resources it owns.
VPIStatus vpiArrayCreate(uint32_t capacity, VPIArrayType fmt, uint32_t flags, VPIArray *array)
Create an empty array instance with the specified flags.
VPIStatus vpiArrayGetType(VPIArray array, VPIArrayType *type)
Get the array type.
VPIArrayType type
Type of each array element.
VPIStatus vpiArraySetSize(VPIArray array, uint32_t size)
Set the array size in elements.
VPIStatus vpiArrayUnlock(VPIArray array)
Releases the lock on array object.
VPIStatus vpiArrayGetSize(VPIArray array, uint32_t *size)
Get the array size in elements.
VPIStatus vpiArrayGetFlags(VPIArray array, uint32_t *flags)
Get the array flags.
uint32_t size
Number of elements in the array.
VPIStatus vpiArrayWrapHostMem(const VPIArrayData *arrayData, uint32_t flags, VPIArray *array)
Create an array object by wrapping around an existing host-memory block.
uint32_t capacity
Maximum number of elements that the array can hold.
void * data
Points to the first element of the array.
VPIArrayType
Array element formats.
Stores information about array characteristics and content.
VPIStatus vpiArrayWrapCudaDeviceMem(const VPIArrayData *arrayData, uint32_t flags, VPIArray *array)
Create an array object by wrapping around an existing device-memory (CUDA) block.
VPILockMode
Defines the lock modes used by memory lock functions.
VPIStatus vpiArrayLock(VPIArray array, VPILockMode mode, VPIArrayData *arrayData)
Acquires the lock on array object and returns a pointer to array data.
VPIStatus vpiArrayGetStride(VPIArray array, uint32_t *stride)
Get the array stride (distance between two consecutive elements) in bytes.
struct VPIArrayImpl * VPIArray
VPIStatus vpiArrayInvalidate(VPIArray array)
This method is useful for unmanaged arrays only (created with 'vpiArrayWrap*`).
VPIStatus vpiArrayGetCapacity(VPIArray array, uint32_t *capacity)
Get the array capacity in elements.
uint32_t stride
Size in bytes of each array element.