diff options
-rw-r--r-- | backend/drm/drm.c | 4 | ||||
-rw-r--r-- | include/backend/drm/drm.h | 1 | ||||
-rw-r--r-- | include/wlr/backend/drm.h | 2 |
3 files changed, 6 insertions, 1 deletions
diff --git a/backend/drm/drm.c b/backend/drm/drm.c index 1fceff95..06f012a3 100644 --- a/backend/drm/drm.c +++ b/backend/drm/drm.c @@ -658,6 +658,10 @@ static struct wlr_output_impl output_impl = { .get_gamma_size = wlr_drm_connector_get_gamma_size, }; +bool wlr_output_is_drm(struct wlr_output *output) { + return output->impl == &output_impl; +} + static int retry_pageflip(void *data) { struct wlr_drm_connector *conn = data; wlr_log(L_INFO, "%s: Retrying pageflip", conn->output.name); diff --git a/include/backend/drm/drm.h b/include/backend/drm/drm.h index 1f70a103..278c387c 100644 --- a/include/backend/drm/drm.h +++ b/include/backend/drm/drm.h @@ -12,7 +12,6 @@ #include <wlr/backend/session.h> #include <wlr/backend/drm.h> -#include <wlr/types/wlr_output.h> #include <wlr/render/egl.h> #include "iface.h" diff --git a/include/wlr/backend/drm.h b/include/wlr/backend/drm.h index b3475703..133e4f69 100644 --- a/include/wlr/backend/drm.h +++ b/include/wlr/backend/drm.h @@ -4,10 +4,12 @@ #include <wayland-server.h> #include <wlr/backend/session.h> #include <wlr/backend.h> +#include <wlr/types/wlr_output.h> struct wlr_backend *wlr_drm_backend_create(struct wl_display *display, struct wlr_session *session, int gpu_fd, struct wlr_backend *parent); bool wlr_backend_is_drm(struct wlr_backend *backend); +bool wlr_output_is_drm(struct wlr_output *output); #endif |