aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/wlr/interfaces/wlr_output.h4
-rw-r--r--include/wlr/types/wlr_gamma_control.h16
-rw-r--r--include/wlr/types/wlr_output.h4
3 files changed, 17 insertions, 7 deletions
diff --git a/include/wlr/interfaces/wlr_output.h b/include/wlr/interfaces/wlr_output.h
index 338d3375..636cc06c 100644
--- a/include/wlr/interfaces/wlr_output.h
+++ b/include/wlr/interfaces/wlr_output.h
@@ -18,8 +18,8 @@ struct wlr_output_impl {
void (*make_current)(struct wlr_output *output);
void (*swap_buffers)(struct wlr_output *output);
void (*set_gamma)(struct wlr_output *output,
- uint16_t size, uint16_t *r, uint16_t *g, uint16_t *b);
- uint16_t (*get_gamma_size)(struct wlr_output *output);
+ uint32_t size, uint16_t *r, uint16_t *g, uint16_t *b);
+ uint32_t (*get_gamma_size)(struct wlr_output *output);
};
void wlr_output_init(struct wlr_output *output, struct wlr_backend *backend,
diff --git a/include/wlr/types/wlr_gamma_control.h b/include/wlr/types/wlr_gamma_control.h
index 96c9f545..59f18494 100644
--- a/include/wlr/types/wlr_gamma_control.h
+++ b/include/wlr/types/wlr_gamma_control.h
@@ -5,18 +5,28 @@
struct wlr_gamma_control_manager {
struct wl_global *wl_global;
+ struct wl_list controls; // list of wlr_gamma_control
void *data;
};
struct wlr_gamma_control {
struct wl_resource *resource;
- struct wl_resource *output;
+ struct wlr_output *output;
+ struct wl_list link;
+
+ struct wl_listener output_destroy_listener;
+
+ struct {
+ struct wl_signal destroy;
+ } events;
void* data;
};
-struct wlr_gamma_control_manager *wlr_gamma_control_manager_create(struct wl_display *display);
-void wlr_gamma_control_manager_destroy(struct wlr_gamma_control_manager *gamma_control_manager);
+struct wlr_gamma_control_manager *wlr_gamma_control_manager_create(
+ struct wl_display *display);
+void wlr_gamma_control_manager_destroy(
+ struct wlr_gamma_control_manager *gamma_control_manager);
#endif
diff --git a/include/wlr/types/wlr_output.h b/include/wlr/types/wlr_output.h
index d8649bbb..74eb15ed 100644
--- a/include/wlr/types/wlr_output.h
+++ b/include/wlr/types/wlr_output.h
@@ -84,7 +84,7 @@ void wlr_output_effective_resolution(struct wlr_output *output,
void wlr_output_make_current(struct wlr_output *output);
void wlr_output_swap_buffers(struct wlr_output *output);
void wlr_output_set_gamma(struct wlr_output *output,
- uint16_t size, uint16_t *r, uint16_t *g, uint16_t *b);
-uint16_t wlr_output_get_gamma_size(struct wlr_output *output);
+ uint32_t size, uint16_t *r, uint16_t *g, uint16_t *b);
+uint32_t wlr_output_get_gamma_size(struct wlr_output *output);
#endif