aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRose Hudson <rose@krx.sh>2023-08-08 20:20:57 +0100
committerSimon Ser <contact@emersion.fr>2023-08-23 16:37:07 +0200
commit462f04db9e70c683a421aa015c1689fff8206781 (patch)
tree055c0b7ee5d2c932b437d11b03954e9843c58003
parentfc81d06addbc72012ca72e4ca9a462f22629a451 (diff)
output: don't forbid multiple commits per frame
It's still not possible to commit while a page flip is pending in DRM, but we don't need to enforce that here and allowing it through the common interface can be useful for other backends. This decouples commits from frame scheduling, which is going to make the new frame schedulers easier to implement.
-rw-r--r--types/output/output.c8
1 files changed, 0 insertions, 8 deletions
diff --git a/types/output/output.c b/types/output/output.c
index 81c4e39e..931b152c 100644
--- a/types/output/output.c
+++ b/types/output/output.c
@@ -652,14 +652,6 @@ static uint32_t output_compare_state(struct wlr_output *output,
static bool output_basic_test(struct wlr_output *output,
const struct wlr_output_state *state) {
if (state->committed & WLR_OUTPUT_STATE_BUFFER) {
- // Modesets will block for the previous frame to complete. Regular
- // page-flips are non-blocking and require the compositor to wait.
- if (output->frame_pending &&
- !(state->committed & (WLR_OUTPUT_STATE_ENABLED | WLR_OUTPUT_STATE_MODE))) {
- wlr_log(WLR_DEBUG, "Tried to commit a buffer while a frame is pending");
- return false;
- }
-
// If the size doesn't match, reject buffer (scaling is not
// supported)
int pending_width, pending_height;