summaryrefslogtreecommitdiffstatshomepage
path: root/3rdparty/bgfx/examples/common/entry/entry_p.h
diff options
context:
space:
mode:
Diffstat (limited to '3rdparty/bgfx/examples/common/entry/entry_p.h')
-rw-r--r--3rdparty/bgfx/examples/common/entry/entry_p.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/3rdparty/bgfx/examples/common/entry/entry_p.h b/3rdparty/bgfx/examples/common/entry/entry_p.h
index 09fa203bde5..39a289ed737 100644
--- a/3rdparty/bgfx/examples/common/entry/entry_p.h
+++ b/3rdparty/bgfx/examples/common/entry/entry_p.h
@@ -6,6 +6,8 @@
#ifndef ENTRY_PRIVATE_H_HEADER_GUARD
#define ENTRY_PRIVATE_H_HEADER_GUARD
+#define TINYSTL_ALLOCATOR entry::TinyStlAllocator
+
#include <bx/spscqueue.h>
#include "entry.h"
@@ -37,11 +39,21 @@
# error "Both ENTRY_DEFAULT_WIDTH and ENTRY_DEFAULT_HEIGHT must be defined."
#endif // ENTRY_DEFAULT_WIDTH
+#ifndef ENTRY_CONFIG_IMPLEMENT_DEFAULT_ALLOCATOR
+# define ENTRY_CONFIG_IMPLEMENT_DEFAULT_ALLOCATOR 1
+#endif // ENTRY_CONFIG_IMPLEMENT_DEFAULT_ALLOCATOR
+
#define ENTRY_IMPLEMENT_EVENT(_class, _type) \
_class(WindowHandle _handle) : Event(_type, _handle) {}
namespace entry
{
+ struct TinyStlAllocator
+ {
+ static void* static_allocate(size_t _bytes);
+ static void static_deallocate(void* _ptr, size_t /*_bytes*/);
+ };
+
int main(int _argc, char** _argv);
struct Event