31 #ifndef _IAKPLUGINMEMALLOC_H_
32 #define _IAKPLUGINMEMALLOC_H_
34 #include <AK/SoundEngine/Common/AkTypes.h>
35 #include <AK/SoundEngine/Common/AkMemoryMgr.h>
68 #if defined (AK_MEMDEBUG)
72 virtual void * dMalloc(
74 const char* in_pszFile,
82 #if defined (AK_MEMDEBUG)
84 AkForceInline
void *
operator</span> new(size_t size,AK::IAkPluginMemAlloc * in_pAllocator,const char* szFile,AkUInt32 ulLine) throw()
86 return in_pAllocator->dMalloc( size, szFile, ulLine );
89 AkForceInline
void operator</span> delete(void *, AK::IAkPluginMemAlloc *, const char*, AkUInt32) throw() {}
95 return in_pAllocator->Malloc( size );
100 #if defined (AK_MEMDEBUG)
101 #define AK_PLUGIN_NEW(_allocator,_what) new((_allocator),__FILE__,__LINE__) _what
102 #define AK_PLUGIN_ALLOC(_allocator,_size) (_allocator)->dMalloc((_size),__FILE__,__LINE__)
112 #define AK_PLUGIN_NEW(_allocator,_what) new(_allocator) _what
121 #define AK_PLUGIN_ALLOC(_allocator,_size) (_allocator)->Malloc((_size))
136 in_pAllocator->
Free( in_pObject );
146 #define AK_PLUGIN_FREE(_allocator,_pvmem) (_allocator)->Free((_pvmem))
148 #endif // _IAKPLUGINMEMALLOC_H_
virtual void * Malloc(size_t in_uSize)=0
virtual ~IAkPluginMemAlloc()
Virtual destructor on interface to avoid warnings.
virtual void Free(void *in_pMemAddress)=0
Tell 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