cAudio  2.3.0
3d Audio Engine
 All Classes Namespaces Functions Variables Enumerations Pages
Public Member Functions | List of all members
cAudio::cStandardMemoryProvider Class Reference

Memory provider that wraps the standard memalloc and free. More...

#include <cStandardMemoryProvider.h>

Inheritance diagram for cAudio::cStandardMemoryProvider:
Inheritance graph
[legend]
Collaboration diagram for cAudio::cStandardMemoryProvider:
Collaboration graph
[legend]

Public Member Functions

virtual void * Allocate (size_t size, const char *filename, int line, const char *function)
 Allocates memory and returns a pointer to it. More...
 
virtual void Free (void *pointer)
 Frees memory previously allocated. More...
 
virtual size_t getMaxAllocationSize ()
 Returns the largest possible single allocation that can be made.
 

Detailed Description

Memory provider that wraps the standard memalloc and free.

Definition at line 13 of file cStandardMemoryProvider.h.

Member Function Documentation

void * cAudio::cStandardMemoryProvider::Allocate ( size_t  size,
const char *  filename,
int  line,
const char *  function 
)
virtual

Allocates memory and returns a pointer to it.

Parameters
size,:Size of the memory chunk to allocate in bytes.
filename,:Filename of the source file that this allocation took place in (in Debug) or NULL otherwise.
line,:Line of the source file where this allocation took place (in Debug) or -1 otherwise.
function,:Function that this allocation took place in (in Debug) or NULL otherwise.
Returns
Pointer to the allocated memory or NULL if allocation failed.

Implements cAudio::IMemoryProvider.

Definition at line 20 of file cStandardMemoryProvider.cpp.

void cAudio::cStandardMemoryProvider::Free ( void *  pointer)
virtual

Frees memory previously allocated.

Parameters
pointer,:Pointer to the memory location to free.

Implements cAudio::IMemoryProvider.

Definition at line 29 of file cStandardMemoryProvider.cpp.


The documentation for this class was generated from the following files: