glcontext_ppapi.h 705 B

1234567891011121314151617181920212223242526272829303132333435
  1. /*
  2. * Copyright 2011-2013 Branimir Karadzic. All rights reserved.
  3. * License: http://www.opensource.org/licenses/BSD-2-Clause
  4. */
  5. #ifndef __GLCONTEXT_PPAPI_H__
  6. #define __GLCONTEXT_PPAPI_H__
  7. #if BX_PLATFORM_NACL
  8. # include <ppapi/gles2/gl2ext_ppapi.h>
  9. # include <ppapi/c/pp_completion_callback.h>
  10. # include <ppapi/c/ppb_instance.h>
  11. # include <ppapi/c/ppb_graphics_3d.h>
  12. namespace bgfx
  13. {
  14. struct GlContext
  15. {
  16. GlContext()
  17. {
  18. }
  19. void create(uint32_t _width, uint32_t _height);
  20. void destroy();
  21. void resize(uint32_t _width, uint32_t _height, bool _vsync);
  22. void swap();
  23. void import();
  24. bool isValid() const;
  25. };
  26. } // namespace bgfx
  27. #endif // BX_PLATFORM_NACL
  28. #endif // __GLCONTEXT_PPAPI_H__