Loading libs/hwui/Properties.cpp +2 −2 Original line number Original line Diff line number Diff line Loading @@ -29,7 +29,7 @@ bool Properties::debugLayersUpdates = false; bool Properties::debugOverdraw = false; bool Properties::debugOverdraw = false; bool Properties::showDirtyRegions = false; bool Properties::showDirtyRegions = false; bool Properties::skipEmptyFrames = true; bool Properties::skipEmptyFrames = true; bool Properties::swapBuffersWithDamage = false; bool Properties::swapBuffersWithDamage = true; DebugLevel Properties::debugLevel = kDebugDisabled; DebugLevel Properties::debugLevel = kDebugDisabled; OverdrawColorSet Properties::overdrawColorSet = OverdrawColorSet::Default; OverdrawColorSet Properties::overdrawColorSet = OverdrawColorSet::Default; Loading Loading @@ -104,7 +104,7 @@ bool Properties::load() { } } skipEmptyFrames = property_get_bool(PROPERTY_SKIP_EMPTY_DAMAGE, true); skipEmptyFrames = property_get_bool(PROPERTY_SKIP_EMPTY_DAMAGE, true); swapBuffersWithDamage = property_get_bool(PROPERTY_SWAP_WITH_DAMAGE, false); swapBuffersWithDamage = property_get_bool(PROPERTY_SWAP_WITH_DAMAGE, true); return (prevDebugLayersUpdates != debugLayersUpdates) return (prevDebugLayersUpdates != debugLayersUpdates) || (prevDebugOverdraw != debugOverdraw) || (prevDebugOverdraw != debugOverdraw) Loading libs/hwui/renderthread/EglManager.cpp +1 −6 Original line number Original line Diff line number Diff line Loading @@ -256,7 +256,7 @@ bool EglManager::swapBuffers(EGLSurface surface, const SkRect& dirty, #endif #endif #ifdef EGL_KHR_swap_buffers_with_damage #ifdef EGL_KHR_swap_buffers_with_damage if (CC_UNLIKELY(Properties::swapBuffersWithDamage)) { if (CC_LIKELY(Properties::swapBuffersWithDamage)) { SkIRect idirty; SkIRect idirty; dirty.roundOut(&idirty); dirty.roundOut(&idirty); /* /* Loading @@ -273,11 +273,6 @@ bool EglManager::swapBuffers(EGLSurface surface, const SkRect& dirty, // layout: {x, y, width, height} // layout: {x, y, width, height} EGLint rects[4] = { idirty.x(), y, idirty.width(), idirty.height() }; EGLint rects[4] = { idirty.x(), y, idirty.width(), idirty.height() }; EGLint numrects = dirty.isEmpty() ? 0 : 1; EGLint numrects = dirty.isEmpty() ? 0 : 1; // TODO: Remove prior to enabling this path by default ALOGD("Swap buffers with damage %d: %d, %d, %d, %d (src=" RECT_STRING ")", dirty.isEmpty() ? 0 : 1, rects[0], rects[1], rects[2], rects[3], SK_RECT_ARGS(dirty)); eglSwapBuffersWithDamageKHR(mEglDisplay, surface, rects, numrects); eglSwapBuffersWithDamageKHR(mEglDisplay, surface, rects, numrects); } else { } else { eglSwapBuffers(mEglDisplay, surface); eglSwapBuffers(mEglDisplay, surface); Loading Loading
libs/hwui/Properties.cpp +2 −2 Original line number Original line Diff line number Diff line Loading @@ -29,7 +29,7 @@ bool Properties::debugLayersUpdates = false; bool Properties::debugOverdraw = false; bool Properties::debugOverdraw = false; bool Properties::showDirtyRegions = false; bool Properties::showDirtyRegions = false; bool Properties::skipEmptyFrames = true; bool Properties::skipEmptyFrames = true; bool Properties::swapBuffersWithDamage = false; bool Properties::swapBuffersWithDamage = true; DebugLevel Properties::debugLevel = kDebugDisabled; DebugLevel Properties::debugLevel = kDebugDisabled; OverdrawColorSet Properties::overdrawColorSet = OverdrawColorSet::Default; OverdrawColorSet Properties::overdrawColorSet = OverdrawColorSet::Default; Loading Loading @@ -104,7 +104,7 @@ bool Properties::load() { } } skipEmptyFrames = property_get_bool(PROPERTY_SKIP_EMPTY_DAMAGE, true); skipEmptyFrames = property_get_bool(PROPERTY_SKIP_EMPTY_DAMAGE, true); swapBuffersWithDamage = property_get_bool(PROPERTY_SWAP_WITH_DAMAGE, false); swapBuffersWithDamage = property_get_bool(PROPERTY_SWAP_WITH_DAMAGE, true); return (prevDebugLayersUpdates != debugLayersUpdates) return (prevDebugLayersUpdates != debugLayersUpdates) || (prevDebugOverdraw != debugOverdraw) || (prevDebugOverdraw != debugOverdraw) Loading
libs/hwui/renderthread/EglManager.cpp +1 −6 Original line number Original line Diff line number Diff line Loading @@ -256,7 +256,7 @@ bool EglManager::swapBuffers(EGLSurface surface, const SkRect& dirty, #endif #endif #ifdef EGL_KHR_swap_buffers_with_damage #ifdef EGL_KHR_swap_buffers_with_damage if (CC_UNLIKELY(Properties::swapBuffersWithDamage)) { if (CC_LIKELY(Properties::swapBuffersWithDamage)) { SkIRect idirty; SkIRect idirty; dirty.roundOut(&idirty); dirty.roundOut(&idirty); /* /* Loading @@ -273,11 +273,6 @@ bool EglManager::swapBuffers(EGLSurface surface, const SkRect& dirty, // layout: {x, y, width, height} // layout: {x, y, width, height} EGLint rects[4] = { idirty.x(), y, idirty.width(), idirty.height() }; EGLint rects[4] = { idirty.x(), y, idirty.width(), idirty.height() }; EGLint numrects = dirty.isEmpty() ? 0 : 1; EGLint numrects = dirty.isEmpty() ? 0 : 1; // TODO: Remove prior to enabling this path by default ALOGD("Swap buffers with damage %d: %d, %d, %d, %d (src=" RECT_STRING ")", dirty.isEmpty() ? 0 : 1, rects[0], rects[1], rects[2], rects[3], SK_RECT_ARGS(dirty)); eglSwapBuffersWithDamageKHR(mEglDisplay, surface, rects, numrects); eglSwapBuffersWithDamageKHR(mEglDisplay, surface, rects, numrects); } else { } else { eglSwapBuffers(mEglDisplay, surface); eglSwapBuffers(mEglDisplay, surface); Loading