Loading libs/hwui/Caches.cpp +1 −1 Original line number Diff line number Diff line Loading @@ -429,7 +429,7 @@ void Caches::resetScissor() { void Caches::startTiling(GLuint x, GLuint y, GLuint width, GLuint height, bool opaque) { if (extensions.hasTiledRendering()) { glStartTilingQCOM(x, y, width, height, GL_COLOR_BUFFER_BIT0_QCOM); glStartTilingQCOM(x, y, width, height, opaque ? GL_NONE : GL_COLOR_BUFFER_BIT0_QCOM); } } Loading libs/hwui/OpenGLRenderer.cpp +3 −10 Original line number Diff line number Diff line Loading @@ -175,7 +175,7 @@ int OpenGLRenderer::prepareDirty(float left, float top, float right, float botto mSaveCount = 1; mSnapshot->setClip(left, top, right, bottom); mDirtyClip = mOpaqueFrame = opaque; mDirtyClip = opaque; // If we know that we are going to redraw the entire framebuffer, // perform a discard to let the driver know we don't need to preserve Loading @@ -189,7 +189,7 @@ int OpenGLRenderer::prepareDirty(float left, float top, float right, float botto syncState(); mTilingSnapshot = mSnapshot; startTiling(); startTiling(mTilingSnapshot, true); if (!opaque) { mCaches.enableScissor(); Loading @@ -213,16 +213,9 @@ void OpenGLRenderer::syncState() { } } void OpenGLRenderer::startTiling() { startTiling(mTilingSnapshot); } void OpenGLRenderer::startTiling(const sp<Snapshot>& s) { bool opaque = mOpaqueFrame; void OpenGLRenderer::startTiling(const sp<Snapshot>& s, bool opaque) { Rect* clip = mTilingSnapshot->clipRect; if (s->flags & Snapshot::kFlagIsFboLayer) { opaque = !s->layer->isBlend(); clip = s->clipRect; } Loading libs/hwui/OpenGLRenderer.h +1 −2 Original line number Diff line number Diff line Loading @@ -351,8 +351,7 @@ private: * This method needs to be invoked every time getTargetFbo() is * bound again. */ void startTiling(); void startTiling(const sp<Snapshot>& snapshot); void startTiling(const sp<Snapshot>& snapshot, bool opaque = false); /** * Tells the GPU that we are done drawing the frame or that we Loading tests/HwAccelerationTest/src/com/android/test/hwui/MultiLayersActivity.java +2 −2 Original line number Diff line number Diff line Loading @@ -45,10 +45,10 @@ public class MultiLayersActivity extends Activity { row1.addView(new LayerView(this, 0xffff0000), new LinearLayout.LayoutParams( 0, LinearLayout.LayoutParams.MATCH_PARENT, 1.0f)); row1.addView(new LayerView(this, 0xff00ff00), new LinearLayout.LayoutParams( row1.addView(new LayerView(this, 0x0f00ff00), new LinearLayout.LayoutParams( 0, LinearLayout.LayoutParams.MATCH_PARENT, 1.0f)); row2.addView(new LayerView(this, 0xff0000ff), new LinearLayout.LayoutParams( row2.addView(new LayerView(this, 0x0f0000ff), new LinearLayout.LayoutParams( 0, LinearLayout.LayoutParams.MATCH_PARENT, 1.0f)); row2.addView(new LayerView(this, 0xffffff00), new LinearLayout.LayoutParams( 0, LinearLayout.LayoutParams.MATCH_PARENT, 1.0f)); Loading Loading
libs/hwui/Caches.cpp +1 −1 Original line number Diff line number Diff line Loading @@ -429,7 +429,7 @@ void Caches::resetScissor() { void Caches::startTiling(GLuint x, GLuint y, GLuint width, GLuint height, bool opaque) { if (extensions.hasTiledRendering()) { glStartTilingQCOM(x, y, width, height, GL_COLOR_BUFFER_BIT0_QCOM); glStartTilingQCOM(x, y, width, height, opaque ? GL_NONE : GL_COLOR_BUFFER_BIT0_QCOM); } } Loading
libs/hwui/OpenGLRenderer.cpp +3 −10 Original line number Diff line number Diff line Loading @@ -175,7 +175,7 @@ int OpenGLRenderer::prepareDirty(float left, float top, float right, float botto mSaveCount = 1; mSnapshot->setClip(left, top, right, bottom); mDirtyClip = mOpaqueFrame = opaque; mDirtyClip = opaque; // If we know that we are going to redraw the entire framebuffer, // perform a discard to let the driver know we don't need to preserve Loading @@ -189,7 +189,7 @@ int OpenGLRenderer::prepareDirty(float left, float top, float right, float botto syncState(); mTilingSnapshot = mSnapshot; startTiling(); startTiling(mTilingSnapshot, true); if (!opaque) { mCaches.enableScissor(); Loading @@ -213,16 +213,9 @@ void OpenGLRenderer::syncState() { } } void OpenGLRenderer::startTiling() { startTiling(mTilingSnapshot); } void OpenGLRenderer::startTiling(const sp<Snapshot>& s) { bool opaque = mOpaqueFrame; void OpenGLRenderer::startTiling(const sp<Snapshot>& s, bool opaque) { Rect* clip = mTilingSnapshot->clipRect; if (s->flags & Snapshot::kFlagIsFboLayer) { opaque = !s->layer->isBlend(); clip = s->clipRect; } Loading
libs/hwui/OpenGLRenderer.h +1 −2 Original line number Diff line number Diff line Loading @@ -351,8 +351,7 @@ private: * This method needs to be invoked every time getTargetFbo() is * bound again. */ void startTiling(); void startTiling(const sp<Snapshot>& snapshot); void startTiling(const sp<Snapshot>& snapshot, bool opaque = false); /** * Tells the GPU that we are done drawing the frame or that we Loading
tests/HwAccelerationTest/src/com/android/test/hwui/MultiLayersActivity.java +2 −2 Original line number Diff line number Diff line Loading @@ -45,10 +45,10 @@ public class MultiLayersActivity extends Activity { row1.addView(new LayerView(this, 0xffff0000), new LinearLayout.LayoutParams( 0, LinearLayout.LayoutParams.MATCH_PARENT, 1.0f)); row1.addView(new LayerView(this, 0xff00ff00), new LinearLayout.LayoutParams( row1.addView(new LayerView(this, 0x0f00ff00), new LinearLayout.LayoutParams( 0, LinearLayout.LayoutParams.MATCH_PARENT, 1.0f)); row2.addView(new LayerView(this, 0xff0000ff), new LinearLayout.LayoutParams( row2.addView(new LayerView(this, 0x0f0000ff), new LinearLayout.LayoutParams( 0, LinearLayout.LayoutParams.MATCH_PARENT, 1.0f)); row2.addView(new LayerView(this, 0xffffff00), new LinearLayout.LayoutParams( 0, LinearLayout.LayoutParams.MATCH_PARENT, 1.0f)); Loading