summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNicolas Roard <nicolas@android.com>2011-02-18 15:54:32 -0800
committerandroid-merger <android-build@android.com>2011-02-22 11:40:37 -0800
commit3201edf0dc826cdad8a086eace280e0fe7eedbd1 (patch)
treee93e82aa822ccdae0825ec5a79c033fee95c1120
parent4162d44830e6a38910c11dba14f22263342e8bb1 (diff)
downloadexternal_webkit-3201edf0dc826cdad8a086eace280e0fe7eedbd1.zip
external_webkit-3201edf0dc826cdad8a086eace280e0fe7eedbd1.tar.gz
external_webkit-3201edf0dc826cdad8a086eace280e0fe7eedbd1.tar.bz2
Do not merge: Cherry-pick Flash performance CL from Master
Bug: 3471589 Fix some of the performance issues when using the flash plugin embedded. What happened was that MediaLayer was always telling us to repaint the screen; we could repaint the same frame a dozen of times unecessarily. This in itself was wasteful but should have been ok, but the stream of commands plus the compositing caused the GPU commands used by flash to stall until they were executed... The compounded impact drasticaly lowered the performances. This is not a full fix as those conditions (us repainting the screen a lot) happens anyway when zooming or scrolling; but this should improve performances in the general case. Change-Id: I79a75c759fd5968cb822616eba0caa8c77e75835
-rw-r--r--WebCore/platform/graphics/android/MediaLayer.cpp7
1 files changed, 1 insertions, 6 deletions
diff --git a/WebCore/platform/graphics/android/MediaLayer.cpp b/WebCore/platform/graphics/android/MediaLayer.cpp
index ad4fc76..d8bbefc 100644
--- a/WebCore/platform/graphics/android/MediaLayer.cpp
+++ b/WebCore/platform/graphics/android/MediaLayer.cpp
@@ -78,8 +78,6 @@ bool MediaLayer::drawGL(SkMatrix& matrix)
// draw any video content if present
m_videoTexture->drawVideo(drawTransform());
- bool needsInval = true;
-
// draw the primary content
if (m_bufferedTexture) {
TextureInfo* textureInfo = m_bufferedTexture->consumerLock();
@@ -103,14 +101,11 @@ bool MediaLayer::drawGL(SkMatrix& matrix)
textureInfo->m_textureId,
1.0f, forceBlending);
}
-
- if (!rect.isEmpty())
- needsInval = false;
}
m_bufferedTexture->consumerRelease();
}
- return drawChildrenGL(matrix) || needsInval;
+ return drawChildrenGL(matrix);
}
ANativeWindow* MediaLayer::acquireNativeWindowForVideo()