Ejemplo n.º 1
0
static boolean
wayland_drm_display_bind_wayland_display(struct native_display *ndpy,
                                         struct wl_display *wl_dpy)
{
   struct wayland_drm_display *drmdpy = wayland_drm_display(ndpy);

   if (drmdpy->wl_server_drm)
      return FALSE;

   drmdpy->wl_server_drm =
      wayland_drm_init(wl_dpy, drmdpy->device_name,
                       &wl_drm_callbacks, ndpy);

   if (!drmdpy->wl_server_drm)
      return FALSE;
   
   return TRUE;
}
Ejemplo n.º 2
0
static boolean
dri2_display_bind_wayland_display(struct native_display *ndpy,
                                  struct wl_display *wl_dpy)
{
   struct dri2_display *dri2dpy = dri2_display(ndpy);

   if (dri2dpy->wl_server_drm)
      return FALSE;

   dri2dpy->wl_server_drm = wayland_drm_init(wl_dpy,
         x11_screen_get_device_name(dri2dpy->xscr),
         &wl_drm_callbacks, ndpy, 0);

   if (!dri2dpy->wl_server_drm)
      return FALSE;
   
   return TRUE;
}