24 | | `Video::SetFov()`: |
25 | | * `glMatrixMode` (not in GLES 2) |
26 | | * `glLoadIdentity` (not in GLES 2) |
27 | | * `glOrtho` (not in GLES 2) |
28 | | * `glFrustum` (not in GLES 2) |
29 | | * `glTranslatef` (not in GLES 2) |
| 15 | Including Linux, Windows. |
| 16 | |
| 17 | {{{ |
| 18 | #define GL_GLEXT_PROTOTYPES |
| 19 | #include <GL/gl.h> |
| 20 | }}} |
| 21 | |
| 22 | === Mac OS X === |
| 23 | |
| 24 | Check for both `__APPLE__` and `__MACH__`. |
| 25 | |
| 26 | {{{ |
| 27 | #define MACOS_OPENGL |
| 28 | #define GL_GLEXT_PROTOTYPES |
| 29 | #include <OpenGL/OpenGL.h> |
| 30 | #include <OpenGL/gl.h> |
| 31 | #include <OpenGL/glext.h> |
| 32 | }}} |
| 33 | |
| 34 | == OpenGL ES headers == |
| 35 | |
| 36 | === Most OpenGL ES platforms === |
| 37 | |
| 38 | Android, NaCl. |
| 39 | |
| 40 | {{{ |
| 41 | #include <GLES2/gl2.h> |
| 42 | #include <GLES2/gl2ext.h> |
| 43 | }}} |
| 44 | |
| 45 | === Apple iOS === |
| 46 | |
| 47 | {{{ |
| 48 | #include <OpenGLES/ES2/gl.h> |
| 49 | #include <OpenGLES/ES2/glext.h> |
| 50 | }}} |
| 51 | |
| 52 | === Old OpenGL ES 1.x systems === |
| 53 | |
| 54 | {{{ |
| 55 | #include <GLES/gl.h> |
| 56 | #include <GLES/glext.h> |
| 57 | }}} |
| 58 | |
| 59 | === PSGL === |
| 60 | |
| 61 | Will include `GLES/gl.h` in turn. |
| 62 | |
| 63 | {{{ |
| 64 | #include <PSGL/psgl.h> |
| 65 | #include <PSGL/psglu.h> |
| 66 | }}} |
| 67 | |
| 68 | == Version Macros == |
| 69 | |
| 70 | === OpenGL === |
| 71 | |
| 72 | All versions of OpenGL provide a version number in addition to the previous versions: |
| 73 | |
| 74 | {{{ |
| 75 | #define GL_VERSION_1_1 1 |
| 76 | #define GL_VERSION_1_2 1 |
| 77 | #define GL_VERSION_1_2_1 1 |
| 78 | #define GL_VERSION_1_3 1 |
| 79 | #define GL_VERSION_1_4 1 |
| 80 | #define GL_VERSION_1_5 1 |
| 81 | |
| 82 | #define GL_VERSION_2_0 1 |
| 83 | #define GL_VERSION_2_1 1 |
| 84 | |
| 85 | #define GL_VERSION_3_0 1 |
| 86 | #define GL_VERSION_3_1 1 |
| 87 | #define GL_VERSION_3_2 1 |
| 88 | #define GL_VERSION_3_3 1 |
| 89 | |
| 90 | #define GL_VERSION_4_0 1 |
| 91 | #define GL_VERSION_4_1 1 |
| 92 | }}} |
| 93 | |
| 94 | === OpenGL ES 1.0 === |
| 95 | |
| 96 | {{{ |
| 97 | #define GL_OES_VERSION_1_0 1 |
| 98 | }}} |
| 99 | |
| 100 | === OpenGL ES 1.1 === |
| 101 | |
| 102 | {{{ |
| 103 | #define GL_VERSION_ES_CM_1_0 1 |
| 104 | #define GL_VERSION_ES_CL_1_0 1 |
| 105 | #define GL_VERSION_ES_CM_1_1 1 |
| 106 | #define GL_VERSION_ES_CL_1_1 1 |
| 107 | }}} |
| 108 | |
| 109 | === OpenGL ES 2.0 === |
| 110 | |
| 111 | {{{ |
| 112 | #define GL_ES_VERSION_2_0 1 |
| 113 | }}} |