bgfxplatform.h 841 B

123456789101112131415161718192021222324252627282930313233343536373839
  1. /*
  2. * Copyright 2011-2013 Branimir Karadzic. All rights reserved.
  3. * License: http://www.opensource.org/licenses/BSD-2-Clause
  4. */
  5. #ifndef __BGFXPLATFORM_H__
  6. #define __BGFXPLATFORM_H__
  7. #include <bx/bx.h>
  8. #if BX_PLATFORM_LINUX
  9. # include <X11/Xlib.h>
  10. namespace bgfx
  11. {
  12. void x11SetDisplayWindow(::Display* _display, ::Window _window);
  13. } // namespace bgfx
  14. #elif BX_PLATFORM_NACL
  15. # include <ppapi/c/ppb_graphics_3d.h>
  16. # include <ppapi/c/ppb_instance.h>
  17. namespace bgfx
  18. {
  19. typedef void (*PostSwapBuffersFn)(uint32_t _width, uint32_t _height);
  20. void naclSetIntefraces(::PP_Instance, const ::PPB_Instance*, const ::PPB_Graphics3D*, PostSwapBuffersFn);
  21. } // namespace bgfx
  22. #elif BX_PLATFORM_WINDOWS
  23. # include <windows.h>
  24. namespace bgfx
  25. {
  26. void winSetHwnd(::HWND _hwnd);
  27. } // namespace bgfx
  28. #endif // BX_PLATFORM_
  29. #endif // __BGFXPLATFORM_H__