Blender V2.61 - r43446
|
#include <MemoryAllocator.h>
Public Member Functions | |
MemoryAllocator () | |
void | destroy () |
UCHAR * | allocate () |
void | deallocate (UCHAR *obj) |
void | printInfo () |
int | getAllocated () |
int | getAll () |
int | getBytes () |
Dynamic memory allocator - allows allocation/deallocation
Note: there are 4 bytes overhead for each allocated yet unused object.
Definition at line 62 of file MemoryAllocator.h.
MemoryAllocator< N >::MemoryAllocator | ( | ) | [inline] |
UCHAR* MemoryAllocator< N >::allocate | ( | ) | [inline, virtual] |
Allocation method
Implements VirtualMemoryAllocator.
Definition at line 164 of file MemoryAllocator.h.
References HEAP_BASE.
void MemoryAllocator< N >::deallocate | ( | UCHAR * | obj | ) | [inline, virtual] |
De-allocation method
Implements VirtualMemoryAllocator.
Definition at line 179 of file MemoryAllocator.h.
References HEAP_BASE.
void MemoryAllocator< N >::destroy | ( | ) | [inline, virtual] |
Destructor
Implements VirtualMemoryAllocator.
Definition at line 146 of file MemoryAllocator.h.
References addon::engine::free(), and i.
int MemoryAllocator< N >::getAll | ( | ) | [inline, virtual] |
Implements VirtualMemoryAllocator.
Definition at line 208 of file MemoryAllocator.h.
Referenced by MemoryAllocator< N >::printInfo().
int MemoryAllocator< N >::getAllocated | ( | ) | [inline, virtual] |
Query methods
Implements VirtualMemoryAllocator.
Definition at line 203 of file MemoryAllocator.h.
Referenced by MemoryAllocator< N >::printInfo().
int MemoryAllocator< N >::getBytes | ( | ) | [inline, virtual] |
Implements VirtualMemoryAllocator.
Definition at line 213 of file MemoryAllocator.h.
References N.
Referenced by MemoryAllocator< N >::printInfo().
void MemoryAllocator< N >::printInfo | ( | ) | [inline, virtual] |
Print information
Implements VirtualMemoryAllocator.
Definition at line 195 of file MemoryAllocator.h.
References MemoryAllocator< N >::getAll(), MemoryAllocator< N >::getAllocated(), and MemoryAllocator< N >::getBytes().