summaryrefslogtreecommitdiff
path: root/opengl/tests/gl_basic/gl_basic.cpp
diff options
context:
space:
mode:
authorChia-I Wu <olv@google.com>2017-11-16 11:45:52 -0800
committerChia-I Wu <olv@google.com>2017-11-20 08:35:28 -0800
commitf9fc8eed35ab374f3dbf0b6ce2c4036efc393c9a (patch)
tree01f9812f4b1a0295cc82b3e975c6773656ec95f1 /opengl/tests/gl_basic/gl_basic.cpp
parent42ddbb44ac92271a60c5bcdcdce8b0235d82f039 (diff)
surfaceflinger: fix fencing when layers become invisible
A layer always holds on to a buffer (after the first one is acquired). When a new buffer comes in, and the layer is visible, it will - acquire the new buffer - present the new buffer to HWC - get the release fence from HWC - associate the old buffer with the release fence and release it But if the layer happens to be becoming invisible, it will go through - acquire the new buffer - destroy the HWC layer and present - release the old buffer without any fence The problem here is that the old buffer is still on screen until the present takes effect (e.g., on next HW vsync). Rendering artifacts may be seen on screen. This commit changes the acquire/release process for layer becoming invisible to - acquire the new buffer - destroy the HWC layer and present - get a fence from HWC - associate the old buffer with the fence and release it We do not require HWC getReleaseFences to return fences for destroyed layers. We can only use the next best fence, the present fence. Bug: 68490054 Test: manual Merged-In: I68bbf392a6681c6512fc0be68a7d17df122f7308 Change-Id: I68bbf392a6681c6512fc0be68a7d17df122f7308
Diffstat (limited to 'opengl/tests/gl_basic/gl_basic.cpp')
0 files changed, 0 insertions, 0 deletions