Changeset View
Changeset View
Standalone View
Standalone View
libkwineffects/kwinglutils_funcs.cpp
Show All 34 Lines | 34 | static void ReadnPixels(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, | |||
---|---|---|---|---|---|
35 | GLenum type, GLsizei bufSize, GLvoid *data); | 35 | GLenum type, GLsizei bufSize, GLvoid *data); | ||
36 | static void GetnUniformfv(GLuint program, GLint location, GLsizei bufSize, GLfloat *params); | 36 | static void GetnUniformfv(GLuint program, GLint location, GLsizei bufSize, GLfloat *params); | ||
37 | 37 | | |||
38 | // GL_ARB_robustness / GL_EXT_robustness | 38 | // GL_ARB_robustness / GL_EXT_robustness | ||
39 | glGetGraphicsResetStatus_func glGetGraphicsResetStatus; | 39 | glGetGraphicsResetStatus_func glGetGraphicsResetStatus; | ||
40 | glReadnPixels_func glReadnPixels; | 40 | glReadnPixels_func glReadnPixels; | ||
41 | glGetnUniformfv_func glGetnUniformfv; | 41 | glGetnUniformfv_func glGetnUniformfv; | ||
42 | 42 | | |||
43 | void glResolveFunctions(std::function<resolveFuncPtr(const char*)> resolveFunction) | 43 | void glResolveFunctions(const std::function<resolveFuncPtr(const char*)> &resolveFunction) | ||
44 | { | 44 | { | ||
45 | const bool haveArbRobustness = hasGLExtension(QByteArrayLiteral("GL_ARB_robustness")); | 45 | const bool haveArbRobustness = hasGLExtension(QByteArrayLiteral("GL_ARB_robustness")); | ||
46 | const bool haveExtRobustness = hasGLExtension(QByteArrayLiteral("GL_EXT_robustness")); | 46 | const bool haveExtRobustness = hasGLExtension(QByteArrayLiteral("GL_EXT_robustness")); | ||
47 | bool robustContext = false; | 47 | bool robustContext = false; | ||
48 | if (GLPlatform::instance()->isGLES()) { | 48 | if (GLPlatform::instance()->isGLES()) { | ||
49 | if (haveExtRobustness) { | 49 | if (haveExtRobustness) { | ||
50 | GLint value = 0; | 50 | GLint value = 0; | ||
51 | glGetIntegerv(GL_CONTEXT_ROBUST_ACCESS_EXT, &value); | 51 | glGetIntegerv(GL_CONTEXT_ROBUST_ACCESS_EXT, &value); | ||
▲ Show 20 Lines • Show All 51 Lines • Show Last 20 Lines |