diff options
author | Samuel Rødal <sroedal@trolltech.com> | 2009-07-29 11:10:29 (GMT) |
---|---|---|
committer | Samuel Rødal <sroedal@trolltech.com> | 2009-07-29 12:12:46 (GMT) |
commit | 6d77428e7013c5f0d69bc86b2d265dd088e37068 (patch) | |
tree | 46606e3e66366b4e92b59a0232a12168dd9397c0 /src/opengl/gl2paintengineex/qpaintengineex_opengl2_p.h | |
parent | b138f9b310baa25bbb6693ff44f32feb3366e2b0 (diff) | |
download | Qt-6d77428e7013c5f0d69bc86b2d265dd088e37068.zip Qt-6d77428e7013c5f0d69bc86b2d265dd088e37068.tar.gz Qt-6d77428e7013c5f0d69bc86b2d265dd088e37068.tar.bz2 |
Optimized single-rect clip case in OpenGL 2 paint engine.
Use scissor based clipping when only dealing with rectangular intersect
clips. As soon as we get any more complex clips (or unite/replace clips)
we fall back to depth buffer based clipping.
Task-number: 258748
Reviewed-by: Tom
Diffstat (limited to 'src/opengl/gl2paintengineex/qpaintengineex_opengl2_p.h')
-rw-r--r-- | src/opengl/gl2paintengineex/qpaintengineex_opengl2_p.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/opengl/gl2paintengineex/qpaintengineex_opengl2_p.h b/src/opengl/gl2paintengineex/qpaintengineex_opengl2_p.h index ec447a3..906817b 100644 --- a/src/opengl/gl2paintengineex/qpaintengineex_opengl2_p.h +++ b/src/opengl/gl2paintengineex/qpaintengineex_opengl2_p.h @@ -86,6 +86,8 @@ public: qreal maxDepth; bool canRestoreClip; + QRect rectangleClip; + bool hasRectangleClip; }; @@ -217,6 +219,7 @@ public: void writeClip(const QVectorPath &path, float depth); void updateDepthScissorTest(); + void setScissor(const QRect &rect); void regenerateDepthClip(); void systemStateChanged(); uint use_system_clip : 1; |