Class ResourceAllocator
Defined in File Allocator.hpp
Inheritance Relationships
Derived Type
public nvcv::MemAllocator
(Class MemAllocator)
Class Documentation
-
class ResourceAllocator
A base class that encapsulates an NVCVResourceAllocator struct
This class is a convenience wrapper around NVCVResourceAllocator. The derived classes expose additional functionality, specific to the resource type being allocated.
Warning
ResourceAllocator does not own the context object pointed to by cdata().ctx. The destruction of ResourceAllocator does not call the cleanup function.
Subclassed by nvcv::MemAllocator
Public Functions
-
ResourceAllocator() = default
-
inline explicit ResourceAllocator(const NVCVResourceAllocator &alloc)
-
inline const NVCVResourceAllocator &cdata() const &
Returns the underlying allocator descriptor
-
inline NVCVResourceAllocator cdata() &&
Returns the underlying allocator descriptor
Public Static Functions
-
static inline constexpr bool IsCompatibleKind(NVCVResourceType)
Protected Functions
-
inline NVCVResourceAllocator &data() &
Protected Attributes
-
NVCVResourceAllocator m_data = {}
-
ResourceAllocator() = default