summaryrefslogtreecommitdiffstats
path: root/libs
diff options
context:
space:
mode:
authorChris Craik <ccraik@google.com>2012-11-28 14:45:04 -0800
committerChris Craik <ccraik@google.com>2012-11-28 14:45:04 -0800
commitd15321bbf57ff7a4615076fefcee5e196c4fc796 (patch)
treedb1880599db3ea7f2faf16daba38f30d788510b1 /libs
parentf0afad008bf78576ff364bcd8bc93b7aa8090b34 (diff)
downloadframeworks_base-d15321bbf57ff7a4615076fefcee5e196c4fc796.zip
frameworks_base-d15321bbf57ff7a4615076fefcee5e196c4fc796.tar.gz
frameworks_base-d15321bbf57ff7a4615076fefcee5e196c4fc796.tar.bz2
Use the same interrupt/resume logic for all functor calls
bug:7093396 The functor was able to change the renderer's blend mode without it being restored in process mode. This single path of updating gl caches reduces likelihood of this occurring in the future. Change-Id: Ie367532f9c683299f02bc4f635d7cb31f96db39f
Diffstat (limited to 'libs')
-rw-r--r--libs/hwui/OpenGLRenderer.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/libs/hwui/OpenGLRenderer.cpp b/libs/hwui/OpenGLRenderer.cpp
index 6787705..bc30738 100644
--- a/libs/hwui/OpenGLRenderer.cpp
+++ b/libs/hwui/OpenGLRenderer.cpp
@@ -339,6 +339,7 @@ status_t OpenGLRenderer::invokeFunctors(Rect& dirty) {
size_t count = mFunctors.size();
if (count > 0) {
+ interrupt();
SortedVector<Functor*> functors(mFunctors);
mFunctors.clear();
@@ -365,10 +366,7 @@ status_t OpenGLRenderer::invokeFunctors(Rect& dirty) {
mFunctors.add(f);
}
}
- // protect against functors binding to other buffers
- mCaches.unbindMeshBuffer();
- mCaches.unbindIndicesBuffer();
- mCaches.activeTexture(0);
+ resume();
}
return result;