Wwise SDK 2022.1.9
_i_ak_plugin_mem_alloc_8h_source
Version
menu_open
link
Wwise SDK 2022.1.9
|
IAkPluginMemAlloc.h
Go to the documentation of this file.
39 /// \akcaution SDK users should never call these function directly, but use memory allocation macros instead. \endakcaution
103 AkForceInline void * operator</span> new( size_t size, AK::IAkPluginMemAlloc * in_pAllocator, const char * szFile, AkUInt32 ulLine) throw()
108 AkForceInline void* operator</span> new(size_t size, AK::IAkPluginMemAlloc* in_pAllocator) throw()
113 AkForceInline void operator</span> delete( void *, AK::IAkPluginMemAlloc *, const char *, AkUInt32 ) throw() {}
135 #define AK_PLUGIN_ALLOC( _allocator, _size ) ( _allocator )->Malloc( ( _size ), __FILE__, __LINE__ )
146 #define AK_PLUGIN_ALLOC_ALIGN( _allocator, _size, _align ) ( _allocator )->Malign( ( _size ), ( _align ), __FILE__, __LINE__ )
157 #define AK_PLUGIN_REALLOC( _allocator, _pmem, _size ) ( _allocator )->Realloc( ( _pmem ), ( _size ), __FILE__, __LINE__ )
169 #define AK_PLUGIN_REALLOC_ALIGN( _allocator, _pmem, _size, _align ) ( _allocator )->ReallocAligned( ( _pmem ), ( _size ), ( _align ), __FILE__, __LINE__ )
197 /// Usage: Initialize the array with Init(AK::IAkPluginMemAlloc* in_pAllocator), passing it the memory allocator received from the host. Then use normally.
205 AkForceInline void* ReAlloc(void* in_pCurrent, size_t in_uOldSize, size_t in_uNewSize) { return AK_PLUGIN_REALLOC(m_pAllocator, in_pCurrent, in_uNewSize); }
AkForceInline void AK_PLUGIN_DELETE(AK::IAkPluginMemAlloc *in_pAllocator, T *in_pObject)
Definition: IAkPluginMemAlloc.h:179
AkForceInline void * Alloc(size_t in_uSize)
Definition: IAkPluginMemAlloc.h:204
AkForceInline AK::IAkPluginMemAlloc * GetAllocator()
Definition: IAkPluginMemAlloc.h:213
virtual void * Malloc(size_t in_uSize, const char *in_pszFile, AkUInt32 in_uLine)=0
AkForceInline void * ReAlloc(void *in_pCurrent, size_t in_uOldSize, size_t in_uNewSize)
Definition: IAkPluginMemAlloc.h:205
AkForceInline void TransferMem(void *&io_pDest, AkPluginArrayAllocator &in_src, void *in_pSrc)
Definition: IAkPluginMemAlloc.h:207
AkForceInline void Init(AK::IAkPluginMemAlloc *in_pAllocator)
Definition: IAkPluginMemAlloc.h:202
Definition: IAkPluginMemAlloc.h:43
virtual void * ReallocAligned(void *in_pMemAddress, size_t in_uSize, size_t in_uAlignment, const char *in_pszFile, AkUInt32 in_uLine)=0
AkForceInline AkPluginArrayAllocator()
Definition: IAkPluginMemAlloc.h:201
virtual void * Realloc(void *in_pMemAddress, size_t in_uSize, const char *in_pszFile, AkUInt32 in_uLine)=0
virtual ~IAkPluginMemAlloc()
Virtual destructor on interface to avoid warnings.
Definition: IAkPluginMemAlloc.h:46
virtual void * Malign(size_t in_uSize, size_t in_uAlignment, const char *in_pszFile, AkUInt32 in_uLine)=0
virtual void Free(void *in_pMemAddress)=0
Definition: IAkPluginMemAlloc.h:199
#define AK_PLUGIN_REALLOC(_allocator, _pmem, _size)
Definition: IAkPluginMemAlloc.h:157
AkForceInline void Free(void *in_pAddress)
Definition: IAkPluginMemAlloc.h:206
Was this page helpful?
Need Support?
Questions? Problems? Need more info? Contact us, and we can help!
Visit our Support pageTell us about your project. We're here to help.
Register your project and we'll help you get started with no strings attached!
Get started with Wwise