summaryrefslogtreecommitdiffstats
path: root/src/opengl/gl2paintengineex/qpaintengineex_opengl2_p.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/opengl/gl2paintengineex/qpaintengineex_opengl2_p.h')
-rw-r--r--src/opengl/gl2paintengineex/qpaintengineex_opengl2_p.h15
1 files changed, 13 insertions, 2 deletions
diff --git a/src/opengl/gl2paintengineex/qpaintengineex_opengl2_p.h b/src/opengl/gl2paintengineex/qpaintengineex_opengl2_p.h
index a2a44c0..ec447a3 100644
--- a/src/opengl/gl2paintengineex/qpaintengineex_opengl2_p.h
+++ b/src/opengl/gl2paintengineex/qpaintengineex_opengl2_p.h
@@ -156,7 +156,7 @@ public:
void updateBrushUniforms();
void updateMatrix();
void updateCompositionMode();
- void updateTextureFilter(GLenum target, GLenum wrapMode, bool smoothPixmapTransform);
+ void updateTextureFilter(GLenum target, GLenum wrapMode, bool smoothPixmapTransform, GLuint id = -1);
void setBrush(const QBrush* brush);
@@ -175,7 +175,8 @@ public:
void fillStencilWithVertexArray(QGL2PEXVertexArray& vertexArray, bool useWindingFill);
// ^ Calls drawVertexArrays to render into stencil buffer
- void prepareForDraw(bool srcPixelsAreOpaque);
+ bool prepareForDraw(bool srcPixelsAreOpaque);
+ // ^ returns whether the current program changed or not
inline void useSimpleShader();
inline QColor premultiplyColor(QColor c, GLfloat opacity);
@@ -198,6 +199,7 @@ public:
bool stencilBufferDirty;
bool depthUniformDirty;
bool simpleShaderDepthUniformDirty;
+ bool opacityUniformDirty;
const QBrush* currentBrush; // May not be the state's brush!
@@ -218,6 +220,15 @@ public:
void regenerateDepthClip();
void systemStateChanged();
uint use_system_clip : 1;
+
+ uint location(QGLEngineShaderManager::Uniform uniform)
+ {
+ return shaderManager->getUniformLocation(uniform);
+ }
+
+ GLuint lastTexture;
+
+ bool needsSync;
};
QT_END_NAMESPACE