aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorVincent Vanlaer <vincent.vanlaer@skynet.be>2018-02-01 20:27:35 +0100
committerVincent Vanlaer <vincent.vanlaer@skynet.be>2018-02-09 17:29:04 +0100
commitcc1229e75e0c0c2cf5ae6d67bc7411c2631deb86 (patch)
tree528e569385d110464518fd1ecb47e1d88a13da55 /include
parent34489dca16ef9e7fd05c161b8b4f2fd5ce5e4ef0 (diff)
Add atomic gamma setting
Diffstat (limited to 'include')
-rw-r--r--include/backend/drm/drm.h5
-rw-r--r--include/backend/drm/iface.h4
-rw-r--r--include/backend/drm/properties.h3
3 files changed, 10 insertions, 2 deletions
diff --git a/include/backend/drm/drm.h b/include/backend/drm/drm.h
index af472ede..782764c8 100644
--- a/include/backend/drm/drm.h
+++ b/include/backend/drm/drm.h
@@ -39,7 +39,10 @@ struct wlr_drm_plane {
struct wlr_drm_crtc {
uint32_t id;
- uint32_t mode_id; // atomic modesetting only
+
+ // Atomic modesetting only
+ uint32_t mode_id;
+ uint32_t gamma_lut;
drmModeAtomicReq *atomic;
union {
diff --git a/include/backend/drm/iface.h b/include/backend/drm/iface.h
index 4a5d2e9d..228b313a 100644
--- a/include/backend/drm/iface.h
+++ b/include/backend/drm/iface.h
@@ -27,6 +27,10 @@ struct wlr_drm_interface {
// Move the cursor on crtc
bool (*crtc_move_cursor)(struct wlr_drm_backend *drm,
struct wlr_drm_crtc *crtc, int x, int y);
+ // Set the gamma lut on crtc
+ bool (*crtc_set_gamma)(struct wlr_drm_backend *drm,
+ struct wlr_drm_crtc *crtc, uint16_t *r, uint16_t *g, uint16_t *b,
+ uint32_t size);
};
extern const struct wlr_drm_interface atomic_iface;
diff --git a/include/backend/drm/properties.h b/include/backend/drm/properties.h
index 7de386ea..119d24c3 100644
--- a/include/backend/drm/properties.h
+++ b/include/backend/drm/properties.h
@@ -32,8 +32,9 @@ union wlr_drm_crtc_props {
uint32_t active;
uint32_t mode_id;
+ uint32_t gamma_lut;
};
- uint32_t props[4];
+ uint32_t props[5];
};
union wlr_drm_plane_props {