summaryrefslogtreecommitdiffstats
path: root/libs
diff options
context:
space:
mode:
authorRama Vaddula <rvaddula@codeaurora.org>2013-09-25 15:55:25 -0700
committerSteve Kondik <shade@chemlab.org>2015-11-20 14:17:39 -0800
commit8eaba5acf30cbdc851811375a8d385d20110cdd4 (patch)
tree3aac0bca21ec21d03f720e43349f849c35c8dccf /libs
parent4e96928f87e288f4b2b36b47bf2e44782d4261b5 (diff)
downloadframeworks_base-8eaba5acf30cbdc851811375a8d385d20110cdd4.zip
frameworks_base-8eaba5acf30cbdc851811375a8d385d20110cdd4.tar.gz
frameworks_base-8eaba5acf30cbdc851811375a8d385d20110cdd4.tar.bz2
Remove opaque check in preparing dirty region
Since preserve swap is enabled, we need to clear the color buffer when the scissor rect is prepared for a new process. This prevents garbage being present from the previous process in the color buffer. CRs-Fixed: 549755 Change-Id: Icd12ae388077b8c9ed329c37314e896500078543
Diffstat (limited to 'libs')
-rw-r--r--libs/hwui/OpenGLRenderer.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/libs/hwui/OpenGLRenderer.cpp b/libs/hwui/OpenGLRenderer.cpp
index 9621b54..c5e709e 100644
--- a/libs/hwui/OpenGLRenderer.cpp
+++ b/libs/hwui/OpenGLRenderer.cpp
@@ -181,6 +181,16 @@ void OpenGLRenderer::discardFramebuffer(float left, float top, float right, floa
}
void OpenGLRenderer::clear(float left, float top, float right, float bottom, bool opaque) {
+#ifdef QCOM_BSP_LEGACY
+ mRenderState.scissor().setEnabled(true);
+ mRenderState.scissor().set(left, getViewportHeight() - bottom, right - left, bottom - top);
+ glClear(GL_COLOR_BUFFER_BIT);
+ mDirty = true;
+ if (opaque) {
+ mRenderState.scissor().reset();
+ return;
+ }
+#else
if (!opaque) {
mRenderState.scissor().setEnabled(true);
mRenderState.scissor().set(left, getViewportHeight() - bottom, right - left, bottom - top);
@@ -190,6 +200,7 @@ void OpenGLRenderer::clear(float left, float top, float right, float bottom, boo
}
mRenderState.scissor().reset();
+#endif
}
void OpenGLRenderer::startTilingCurrentClip(bool opaque, bool expand) {