@ -26,6 +26,12 @@ struct wlr_fbox;
struct wlr_renderer {
struct {
struct wl_signal destroy;
/**
* Emitted when the GPU is lost, e.g. on GPU reset.
*
* Compositors should destroy the renderer and re-create it.
*/
struct wl_signal lost;
} events;
// private state
@ -44,6 +44,7 @@ void wlr_renderer_init(struct wlr_renderer *renderer,
renderer->impl = impl;
wl_signal_init(&renderer->events.destroy);
wl_signal_init(&renderer->events.lost);
}
void wlr_renderer_destroy(struct wlr_renderer *r) {