Function nvcvTensorDecRef
Defined in File Tensor.h
Function Documentation
-
NVCVStatus nvcvTensorDecRef(NVCVTensorHandle handle, int *newRefCount)
Decrements the reference count of an existing tensor instance.
The tensor is destroyed when its reference count reaches zero.
If the tensor is wrapping external data and a cleanup function has been defined, defined, it will be called.
Note
The tensor object must not be in use in current and future operations.
- Parameters:
handle – [in] Tensor to be destroyed. If NULL, no operation is performed, successfully.
The handle must have been created with any of the nvcvTensorConstruct functions.
newRefCount – [out] The decremented reference count. If the return value is 0, the object was destroyed. Can be NULL, if the caller isn’t interested in the new reference count.
- Return values:
NVCV_ERROR_INVALID_ARGUMENT – The handle is invalid
NVCV_SUCCESS – Operation executed successfully.