diff options
author | Leith Bade <leith@mapbox.com> | 2014-11-23 10:18:13 +1100 |
---|---|---|
committer | Leith Bade <leith@mapbox.com> | 2014-12-06 14:21:08 +1100 |
commit | 6df4e4a52ca0f70e7fdc5166467ab4a868e3bac5 (patch) | |
tree | df52abe9db0e2f2462b92fc322277497b388a131 /include | |
parent | ff640132de0fe855314a8fd86adae3a2fb33237b (diff) | |
download | qtlocation-mapboxgl-6df4e4a52ca0f70e7fdc5166467ab4a868e3bac5.tar.gz |
Load program binary extension on Linux
Diffstat (limited to 'include')
-rw-r--r-- | include/mbgl/platform/gl.hpp | 12 | ||||
-rw-r--r-- | include/mbgl/platform/platform.hpp | 3 |
2 files changed, 15 insertions, 0 deletions
diff --git a/include/mbgl/platform/gl.hpp b/include/mbgl/platform/gl.hpp index d16478dab9..6a35ab8006 100644 --- a/include/mbgl/platform/gl.hpp +++ b/include/mbgl/platform/gl.hpp @@ -118,6 +118,7 @@ typedef void (* PFNGLGETOBJECTLABELEXTPROC) (GLenum type, GLuint object, GLsizei extern PFNGLLABELOBJECTEXTPROC LabelObjectEXT; extern PFNGLGETOBJECTLABELEXTPROC GetObjectLabelEXT; +// GL_ARB_vertex_array_object / GL_OES_vertex_array_object #define GL_VERTEX_ARRAY_BINDING 0x85B5 typedef void (* PFNGLBINDVERTEXARRAYPROC) (GLuint array); typedef void (* PFNGLDELETEVERTEXARRAYSPROC) (GLsizei n, const GLuint* arrays); @@ -128,6 +129,17 @@ extern PFNGLDELETEVERTEXARRAYSPROC DeleteVertexArrays; extern PFNGLGENVERTEXARRAYSPROC GenVertexArrays; extern PFNGLISVERTEXARRAYPROC IsVertexArray; +// GL_ARB_get_program_binary / GL_OES_get_program_binary +#define GL_PROGRAM_BINARY_RETRIEVABLE_HINT 0x8257 +#define GL_PROGRAM_BINARY_LENGTH 0x8741 +#define GL_NUM_PROGRAM_BINARY_FORMATS 0x87FE +#define GL_PROGRAM_BINARY_FORMATS 0x87FF +typedef void (* PFNGLGETPROGRAMBINARYPROC) (GLuint program, GLsizei bufSize, GLsizei *length, GLenum *binaryFormat, void *binary); +typedef void (* PFNGLPROGRAMBINARYPROC) (GLuint program, GLenum binaryFormat, const void *binary, GLsizei length); +typedef void (* PFNGLPROGRAMPARAMETERIPROC) (GLuint program, GLenum pname, GLint value); +extern PFNGLGETPROGRAMBINARYPROC GetProgramBinary; +extern PFNGLPROGRAMBINARYPROC ProgramBinary; +extern PFNGLPROGRAMPARAMETERIPROC ProgramParameteri; // Debug group markers, useful for debugging on iOS #if defined(DEBUG) diff --git a/include/mbgl/platform/platform.hpp b/include/mbgl/platform/platform.hpp index b7107bb9cd..9edcc23ccd 100644 --- a/include/mbgl/platform/platform.hpp +++ b/include/mbgl/platform/platform.hpp @@ -20,6 +20,9 @@ std::string lowercase(const std::string &string); // Returns the path to the default cache database on this system. std::string defaultCacheDatabase(); +// Returns the path to the default shader cache on this system. +std::string defaultShaderCache(); + // Shows an alpha image with the specified dimensions in a named window. void show_debug_image(std::string name, const char *data, size_t width, size_t height); |