NW4F Snd
Loading...
Searching...
No Matches
nw::snd::SoundHeap Class Reference

#include <snd_SoundHeap.h>

Inherits nw::snd::SoundMemoryAllocatable.

Public Types

typedef void(* DisposeCallback) (void *mem, unsigned long size, void *userArg)

Public Member Functions

 SoundHeap ()
virtual ~SoundHeap ()
bool Create (void *startAddress, size_t size)
void Destroy ()
virtual void * Alloc (size_t size)
void * Alloc (size_t size, DisposeCallback callback, void *callbackArg)
void Clear ()
bool IsValid () const
int SaveState ()
void LoadState (int level)
int GetCurrentLevel () const
size_t GetSize () const
size_t GetFreeSize () const
void Dump (nw::snd::SoundDataManager &mgr, nw::snd::SoundArchive &arc) const
Public Member Functions inherited from nw::snd::SoundMemoryAllocatable
virtual ~SoundMemoryAllocatable ()

Static Private Member Functions

static void DisposeCallbackFunc (void *mem, unsigned long size, void *arg)

Private Attributes

ut::CriticalSection m_CriticalSection
internal::FrameHeap m_FrameHeap

Member Typedef Documentation

◆ DisposeCallback

typedef void(* nw::snd::SoundHeap::DisposeCallback) (void *mem, unsigned long size, void *userArg)

Constructor & Destructor Documentation

◆ SoundHeap()

nw::snd::SoundHeap::SoundHeap ( )

◆ ~SoundHeap()

virtual nw::snd::SoundHeap::~SoundHeap ( )
virtual

Member Function Documentation

◆ Create()

bool nw::snd::SoundHeap::Create ( void * startAddress,
size_t size )

◆ Destroy()

void nw::snd::SoundHeap::Destroy ( )

◆ Alloc() [1/2]

virtual void * nw::snd::SoundHeap::Alloc ( size_t size)
virtual

◆ Alloc() [2/2]

void * nw::snd::SoundHeap::Alloc ( size_t size,
DisposeCallback callback,
void * callbackArg )

◆ Clear()

void nw::snd::SoundHeap::Clear ( )

◆ IsValid()

bool nw::snd::SoundHeap::IsValid ( ) const
inline

◆ SaveState()

int nw::snd::SoundHeap::SaveState ( )

◆ LoadState()

void nw::snd::SoundHeap::LoadState ( int level)

◆ GetCurrentLevel()

int nw::snd::SoundHeap::GetCurrentLevel ( ) const
inline

◆ GetSize()

size_t nw::snd::SoundHeap::GetSize ( ) const
inline

◆ GetFreeSize()

size_t nw::snd::SoundHeap::GetFreeSize ( ) const
inline

◆ Dump()

void nw::snd::SoundHeap::Dump ( nw::snd::SoundDataManager & mgr,
nw::snd::SoundArchive & arc ) const
inline

◆ DisposeCallbackFunc()

void nw::snd::SoundHeap::DisposeCallbackFunc ( void * mem,
unsigned long size,
void * arg )
staticprivate

Member Data Documentation

◆ m_CriticalSection

ut::CriticalSection nw::snd::SoundHeap::m_CriticalSection
mutableprivate

◆ m_FrameHeap

internal::FrameHeap nw::snd::SoundHeap::m_FrameHeap
private