bbopengl_.h 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101
  1. #ifndef BB_OPENGL_H
  2. #define BB_OPENGL_H
  3. #include <stddef.h>
  4. //prevents confusion between 1001 GL headers - pinched from glew...
  5. //
  6. #if defined(__gl_h_) || defined(__GL_H__) || defined(_GL_H) || defined(__X_GL_H)
  7. #error gl.h included before bbopengl.h
  8. #endif
  9. #if defined(__gl2_h_)
  10. #error gl2.h included before bbopengl.h
  11. #endif
  12. #if defined(__gltypes_h_)
  13. #error gltypes.h included before bbopengl.h
  14. #endif
  15. #if defined(__REGAL_H__)
  16. #error Regal.h included before bbopengl.h
  17. #endif
  18. #if defined(__glext_h_) || defined(__GLEXT_H_)
  19. #error glext.h included before bbopengl.h
  20. #endif
  21. #if defined(__gl_ATI_h_)
  22. #error glATI.h included before bbopengl.h
  23. #endif
  24. #define __gl_h_
  25. #define __gl2_h_
  26. #define __GL_H__
  27. #define _GL_H
  28. #define __gltypes_h_
  29. #define __REGAL_H__
  30. #define __X_GL_H
  31. #define __glext_h_
  32. #define __GLEXT_H_
  33. #define __gl_ATI_h_
  34. #ifdef __cplusplus
  35. extern "C"{
  36. #endif
  37. #ifndef GLAPI
  38. #define GLAPI extern
  39. #endif
  40. #if _WIN32
  41. #define GLAPIENTRY __stdcall
  42. #else
  43. #define GLAPIENTRY
  44. #endif
  45. #if __EMSCRIPTEN__
  46. #define GLFUN(X) X
  47. #else
  48. #define GLFUN(X) (GLAPIENTRY*bb##X)
  49. #endif
  50. void bbglInit();
  51. GLAPI int BBGL_ES;
  52. GLAPI int BBGL_draw_buffers;
  53. GLAPI int BBGL_depth_texture;
  54. GLAPI int BBGL_seamless_cube_map;
  55. GLAPI int BBGL_texture_filter_anisotropic;
  56. GLAPI int BBGL_standard_derivatives;
  57. typedef unsigned int GLenum;
  58. typedef unsigned int GLbitfield;
  59. typedef unsigned int GLuint;
  60. typedef int GLint;
  61. typedef int GLsizei;
  62. typedef unsigned char GLboolean;
  63. typedef signed char GLbyte;
  64. typedef short GLshort;
  65. typedef unsigned char GLubyte;
  66. typedef unsigned short GLushort;
  67. typedef unsigned long GLulong;
  68. typedef float GLfloat;
  69. typedef float GLclampf;
  70. typedef double GLdouble;
  71. typedef double GLclampd;
  72. typedef void GLvoid;
  73. typedef char GLchar;
  74. typedef ptrdiff_t GLintptr;
  75. typedef ptrdiff_t GLsizeiptr;
  76. typedef struct __GLsync *GLsync;
  77. ${DEFS}
  78. ${DECLS}
  79. #if !__EMSCRIPTEN__
  80. ${CDEFS}
  81. #endif
  82. #ifdef __cplusplus
  83. }
  84. #endif
  85. #endif