aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--backend/drm/drm.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/backend/drm/drm.c b/backend/drm/drm.c
index 70e6a1cf..15be16bc 100644
--- a/backend/drm/drm.c
+++ b/backend/drm/drm.c
@@ -232,10 +232,15 @@ static void wlr_drm_connector_set_gamma(struct wlr_output *output,
uint32_t size, uint16_t *r, uint16_t *g, uint16_t *b) {
struct wlr_drm_connector *conn = (struct wlr_drm_connector *)output;
struct wlr_drm_backend *drm = (struct wlr_drm_backend *)output->backend;
+ bool ok;
if (conn->crtc) {
- drm->iface->crtc_set_gamma(drm, conn->crtc, r, g, b, size);
+ ok = drm->iface->crtc_set_gamma(drm, conn->crtc, r, g, b, size);
+ if (ok) {
+ wlr_output_update_needs_swap(output);
+ }
}
+
}
static uint32_t wlr_drm_connector_get_gamma_size(struct wlr_output *output) {