Adding Music Playback
This commit is contained in:
parent
7b325244c5
commit
231b30b2cb
12 changed files with 1840 additions and 149 deletions
|
|
@ -1,12 +1,22 @@
|
|||
|
||||
#include "Allocators.hpp"
|
||||
#include "HeapAllocatorGlobal.hpp"
|
||||
|
||||
#include <cstdlib>
|
||||
#include <stdio.h>
|
||||
|
||||
static bool init(const tp::ModuleManifest* self) {
|
||||
tp::HeapAllocGlobal::stopIgnore();
|
||||
if (tp::HeapAllocGlobal::getNAllocations()) {
|
||||
printf("Warning : Operator new was called outside module initialization!!\n\n");
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
static void deinit(const tp::ModuleManifest* self) { tp::HeapAllocGlobal::checkLeaks(); }
|
||||
|
||||
static tp::ModuleManifest* sModuleDependencies[] = { &tp::gModuleUtils, nullptr };
|
||||
tp::ModuleManifest tp::gModuleAllocators = ModuleManifest("Allocators", nullptr, deinit, sModuleDependencies);
|
||||
tp::ModuleManifest tp::gModuleAllocators = ModuleManifest("Allocators", init, deinit, sModuleDependencies);
|
||||
|
||||
void* operator new(size_t aSize) { return tp::HeapAllocGlobal::allocate(aSize); }
|
||||
void* operator new[](size_t aSize) { return tp::HeapAllocGlobal::allocate(aSize); }
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue