Bug 1654169 - Use single buffered mode surface as sync surfacce if possible r=geckoview-reviewers,snorp

Single buffered mode surface could reduce memory usage.

Differential Revision: https://phabricator.services.mozilla.com/D84296
This commit is contained in:
sotaro 2020-07-23 18:17:04 +00:00
Родитель 11395cf9ff
Коммит ef1444274c
1 изменённых файлов: 1 добавлений и 1 удалений

Просмотреть файл

@ -116,7 +116,7 @@ public final class GeckoSurface extends Surface {
if (GeckoSurfaceTexture.lookup(mHandle) != null) {
throw new AssertionError("texture#" + mHandle + " already in use.");
}
GeckoSurfaceTexture texture = GeckoSurfaceTexture.acquire(false, mHandle);
GeckoSurfaceTexture texture = GeckoSurfaceTexture.acquire(GeckoSurfaceTexture.isSingleBufferSupported(), mHandle);
texture.setDefaultBufferSize(width, height);
texture.track(mHandle);
mSyncSurface = new GeckoSurface(texture);