Function nvcvArrayCalcRequirementsWithTarget

Function Documentation

NVCVStatus nvcvArrayCalcRequirementsWithTarget(int64_t capacity, NVCVDataType dtype, int32_t alignment, NVCVResourceType target, NVCVArrayRequirements *reqs)

Calculates the resource requirements needed to create an array with target resource.

Parameters:
  • capacity[in] Capacity of the array.

  • dtype[in] Type of array’s elements.

  • alignment[in] Alignment, in bytes, of the array elements. If 0, use a default suitable for optimized memory access. The used alignment is at least the given value. If not 0, it must be a positive integer power-of-two (i.e. 2^n).

  • target[in] The target compute resource for where memory allocation for the data contained within the array will occure.

  • reqs[out] Pointer to the array requirements object. Must not be NULL.

Return values:
  • NVCV_ERROR_INVALID_ARGUMENT – Some parameter is outside valid range.

  • NVCV_SUCCESS – Operation executed successfully.