diff options
author | 2021-05-18 13:57:02 -0700 | |
---|---|---|
committer | 2021-06-17 14:31:02 -0700 | |
commit | 0bde6b5a9837ab96484c988bb3f148d0b9b3ab4e (patch) | |
tree | 6d3bf4cefcd3e2051eed6e126f4cac569703404a /libs/gui/SurfaceControl.cpp | |
parent | 603a15d295579ea583fbad2cb9c15cf41dd598dc (diff) |
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
Diffstat (limited to 'libs/gui/SurfaceControl.cpp')
-rw-r--r-- | libs/gui/SurfaceControl.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
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<Surface> 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<BLASTBufferQueue>::make("bbq-adapter", mBbqChild, mWidth, mHeight, mFormat); // This surface is always consumed by SurfaceFlinger, so the // producerControlledByApp value doesn't matter; using false. |