~ruther/dwl

ref: ae65c517e5da52488a2e0d422a9160532b6de100 dwl/output.c -rw-r--r-- 507 bytes
ae65c517 — wochap feat: implement the output power management protocol 1 year, 4 months ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#include <pixman.h>
#include <wlr/interfaces/wlr_output.h>

void wlr_output_damage_whole(struct wlr_output *output) {
	int width, height;
	pixman_region32_t damage;
	struct wlr_output_event_damage event;

	wlr_output_transformed_resolution(output, &width, &height);

	pixman_region32_init_rect(&damage, 0, 0, width, height);

	event = (struct wlr_output_event_damage){
		.output = output,
		.damage = &damage,
	};
	wl_signal_emit_mutable(&output->events.damage, &event);

	pixman_region32_fini(&damage);
}
Do not follow this link