Common.h 961 B

12345678910111213141516171819202122232425262728293031323334
  1. // Copyright (C) 2009-present, Panagiotis Christopoulos Charitos and contributors.
  2. // All rights reserved.
  3. // Code licensed under the BSD License.
  4. // http://www.anki3d.org/LICENSE
  5. #pragma once
  6. #include <AnKi/Util/StdTypes.h>
  7. #include <AnKi/Util/MemoryPool.h>
  8. namespace anki {
  9. #define ANKI_WIND_LOGI(...) ANKI_LOG("WIND", kNormal, __VA_ARGS__)
  10. #define ANKI_WIND_LOGE(...) ANKI_LOG("WIND", kError, __VA_ARGS__)
  11. #define ANKI_WIND_LOGW(...) ANKI_LOG("WIND", kWarning, __VA_ARGS__)
  12. #define ANKI_WIND_LOGF(...) ANKI_LOG("WIND", kFatal, __VA_ARGS__)
  13. class WindowMemoryPool : public HeapMemoryPool, public MakeSingleton<WindowMemoryPool>
  14. {
  15. template<typename>
  16. friend class MakeSingleton;
  17. private:
  18. WindowMemoryPool(AllocAlignedCallback allocCb, void* allocCbUserData)
  19. : HeapMemoryPool(allocCb, allocCbUserData, "WindowMemPool")
  20. {
  21. }
  22. ~WindowMemoryPool() = default;
  23. };
  24. ANKI_DEFINE_SUBMODULE_UTIL_CONTAINERS(Window, WindowMemoryPool)
  25. } // end namespace anki