diff options
| author | Daniel Eklöf <daniel@ekloef.se> | 2021-05-07 16:18:35 +0000 |
|---|---|---|
| committer | Daniel Eklöf <daniel@ekloef.se> | 2021-05-12 18:06:04 +0000 |
| commit | c8b342ae51cba357f21a3f6c77f6a527981101b8 (patch) | |
| tree | 1c6b4a2b31997883b9c4cc5c0182c8a1863e2401 /shm.h | |
| parent | wayland: codespell: pre-empt -> preempt (diff) | |
shm: track busy buffers’ age, and add compile-time option to force double buffering
By default, age all matching buffers that are busy (i.e. in use by the
compositor).
This allows us to detect whether we can apply the current frame’s
damage directly, or if we need to prepare the buffer first (e.g. copy
old buffer, or re-apply last frame’s damage etc).
Diffstat (limited to 'shm.h')
| -rw-r--r-- | shm.h | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -32,6 +32,8 @@ struct buffer { bool scrollable; bool purge; /* True if this buffer should be destroyed */ + + int age; }; struct buffer *shm_get_buffer( |
