From 0bde6b5a9837ab96484c988bb3f148d0b9b3ab4e Mon Sep 17 00:00:00 2001 From: Ady Abraham Date: Tue, 18 May 2021 13:57:02 -0700 Subject: SF: increase the number of buffers for SurfaceView 3 buffers are not sufficient for most apps to render at high refresh rates. This change increases the maxAcquiredBufferCount on the buffer queue for all surfaces, and removes the hwui-specific extra buffer allocations. All Surfaces connected to SurfaceFlinger will have now enough buffers to account for configured 'debug.sf.late.app.duration' value. Test: Run backpressure based game on 60Hz and 120Hz and collect traces Bug: 188553729 Change-Id: Ib8fda5db3f48c3bfc6fbf07167b4313674512cee --- libs/gui/SurfaceControl.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'libs/gui/SurfaceControl.cpp') diff --git a/libs/gui/SurfaceControl.cpp b/libs/gui/SurfaceControl.cpp index d7c07b9755..6529a4e51c 100644 --- a/libs/gui/SurfaceControl.cpp +++ b/libs/gui/SurfaceControl.cpp @@ -139,7 +139,7 @@ sp SurfaceControl::generateSurfaceLocked() ISurfaceComposerClient::eOpaque); mBbqChild = mClient->createSurface(String8("bbq-wrapper"), 0, 0, mFormat, flags, mHandle, {}, &ignore); - mBbq = new BLASTBufferQueue("bbq-adapter", mBbqChild, mWidth, mHeight, mFormat); + mBbq = sp::make("bbq-adapter", mBbqChild, mWidth, mHeight, mFormat); // This surface is always consumed by SurfaceFlinger, so the // producerControlledByApp value doesn't matter; using false. -- cgit v1.2.3-59-g8ed1b