Warning: you were redirected to the latest documentation corresponding to your major release ( 2019.2.15.7667 ). Should you wish to access your specific version's documentation, please download the offline documentation from the Audiokinetic Launcher and check the Offline Documentation option in Wwise Authoring.
Go to the documentation of this file.
34 template <AkMemID T_MEMID>
39 return AkAlloc(T_MEMID, in_uSize);
44 AkFree(T_MEMID, in_pAddress);
48 template <AkMemID T_MEMID>
66 template <
class T,
class TAlloc = AkRingBufferAllocatorDefault>
75 , m_nbReadableItems(0)
84 m_nbReadableItems = 0;
86 m_data =
reinterpret_cast<T*
>(TAlloc::Alloc(m_nbItems *
sizeof(T)));
99 m_nbReadableItems = 0;
117 return &m_data[m_writeIndex];
124 m_writeIndex = (m_writeIndex + nbItems) % m_nbItems;
138 return &m_data[m_readIndex];
145 m_readIndex = (m_readIndex + nbItems) % m_nbItems;
152 return m_nbReadableItems;
157 return m_nbItems - m_nbReadableItems;
AkUInt32 GetReadIndex() const
const T * GetReadPtr() const
AkUInt32 GetWriteIndex() const
#define AkFree(_pool, _pvmem)
static AkForceInline void Free(void *in_pAddress)
AKSOUNDENGINE_API void Free(AkMemPoolId in_poolId, void *in_pMemAddress)
static AkForceInline void * Alloc(size_t in_uSize)
AKRESULT
Standard function call result.
AkRingBufferAllocatorAligned< AkMemID_Processing > AkRingBufferAllocatorLEngineAligned
static AkForceInline void * Alloc(size_t in_uSize)
AkRingBufferAllocatorNoAlign< AkMemID_Object > AkRingBufferAllocatorDefault
#define AkAlloc(_pool, _size)
@ AK_Success
The operation was successful.
static AkForceInline void Free(void *in_pAddress)
void IncrementReadIndex(AkUInt32 nbItems)
AkUInt32 GetNbReadableItems() const
AkUInt32 GetNbWritableItems() const
#define AKASSERT(Condition)
AKRESULT Init(AkUInt32 nbItems)
#define AkMalign(_pool, _size, _align)
#define AkFalign(_pool, _pvmem)
void IncrementWriteIndex(AkUInt32 nbItems)
@ AK_InsufficientMemory
Memory error.
AkRingBufferAllocatorNoAlign< AkMemID_Processing > AkRingBufferAllocatorLEngine
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