Exemplo n.º 1
0
static struct pipe_screen *create_screen(int fd)
{
   struct radeon_winsys *radeon;

   radeon = radeon_drm_winsys_create(fd, radeonsi_screen_create);
   return radeon ? debug_screen_wrap(radeon->screen) : NULL;
}
Exemplo n.º 2
0
static struct pipe_screen *
create_screen(int fd)
{
   struct radeon_winsys *sws;

   sws = radeon_drm_winsys_create(fd, r300_screen_create);
   return sws ? debug_screen_wrap(sws->screen) : NULL;
}
Exemplo n.º 3
0
static struct pipe_screen *
create_screen(int fd, unsigned flags)
{
   struct radeon_winsys *rw;

   rw = radeon_drm_winsys_create(fd, flags, r600_screen_create);
   return rw ? debug_screen_wrap(rw->screen) : NULL;
}
Exemplo n.º 4
0
static struct pipe_screen *
pipe_radeonsi_create_screen(int fd)
{
#if _EGL_PIPE_RADEONSI
   struct radeon_winsys *rw;

   rw = radeon_drm_winsys_create(fd, radeonsi_screen_create);
   return rw ? debug_screen_wrap(rw->screen) : NULL;
#else
   return NULL;
#endif
}
Exemplo n.º 5
0
static struct pipe_screen *
pipe_r300_create_screen(int fd)
{
#if _EGL_PIPE_R300
   struct radeon_winsys *sws;

   sws = radeon_drm_winsys_create(fd, r300_screen_create);
   return sws ? debug_screen_wrap(sws->screen) : NULL;
#else
   return NULL;
#endif
}
static int pipe_init_screen(struct pipe_manager *pm)
{
	struct pipe_screen *screen = NULL;

#ifdef ENABLE_PIPE_NOUVEAU
	if (strcmp(pm->driver, "nouveau") == 0)
		screen = nouveau_drm_screen_create(pm->fd);
#endif
#ifdef ENABLE_PIPE_R300
	if (strcmp(pm->driver, "r300") == 0) {
		struct radeon_winsys *sws = radeon_drm_winsys_create(pm->fd);

		if (sws) {
			screen = r300_screen_create(sws);
			if (!screen)
				sws->destroy(sws);
		}
	}
#endif
#ifdef ENABLE_PIPE_R600
	if (strcmp(pm->driver, "r600") == 0) {
		struct radeon *rw = r600_drm_winsys_create(pm->fd);

		if (rw) {
			screen = r600_screen_create(rw);
			if (!screen)
				FREE(rw);
		}
	}
#endif
#ifdef ENABLE_PIPE_VMWGFX
	if (strcmp(pm->driver, "vmwgfx") == 0) {
		struct svga_winsys_screen *sws =
			svga_drm_winsys_screen_create(pm->fd);

		if (sws) {
			screen = svga_screen_create(sws);
			if (!screen)
				sws->destroy(sws);
		}
	}
#endif

	if (!screen) {
		LOGW("failed to create screen for %s", pm->driver);
		return -EINVAL;
	}

	pm->screen = debug_screen_wrap(screen);

	return 0;
}
Exemplo n.º 7
0
static struct pipe_screen *create_screen(int fd)
{
   struct radeon_winsys *radeon;
   struct pipe_screen *screen;

   radeon = radeon_drm_winsys_create(fd);
   if (!radeon)
      return NULL;

   screen = r600_screen_create(radeon);
   if (!screen)
      return NULL;

   screen = debug_screen_wrap(screen);

   return screen;
}
Exemplo n.º 8
0
static struct pipe_screen *
create_screen(int fd)
{
   struct radeon_winsys *sws;
   struct pipe_screen *screen;

   sws = radeon_drm_winsys_create(fd);
   if (!sws)
      return NULL;

   screen = r300_screen_create(sws);
   if (!screen)
      return NULL;

   screen = debug_screen_wrap(screen);

   return screen;
}
Exemplo n.º 9
0
static struct pipe_screen *create_screen(int fd)
{
    struct radeon_winsys *radeon;

    radeon = radeon_drm_winsys_create(fd);
    if (!radeon)
        return NULL;

    if (!radeon->screen) {
        radeon->screen = r600_screen_create(radeon);
        if (!radeon->screen)
            return NULL;

        radeon->screen = debug_screen_wrap(radeon->screen);
    }

    return radeon->screen;
}
Exemplo n.º 10
0
static struct pipe_screen *
pipe_radeonsi_create_screen(int fd)
{
#if _EGL_PIPE_RADEONSI
   struct radeon_winsys *rw;
   struct pipe_screen *screen;

   rw = radeon_drm_winsys_create(fd);
   if (!rw)
      return NULL;

   screen = radeonsi_screen_create(rw);
   if (!screen)
      return NULL;

   screen = debug_screen_wrap(screen);

   return screen;
#else
   return NULL;
#endif
}
Exemplo n.º 11
0
static struct pipe_screen *
pipe_r300_create_screen(int fd)
{
#if _EGL_PIPE_R300
   struct radeon_winsys *sws;
   struct pipe_screen *screen;

   sws = radeon_drm_winsys_create(fd);
   if (!sws)
      return NULL;

   screen = r300_screen_create(sws);
   if (!screen)
      return NULL;

   screen = debug_screen_wrap(screen);

   return screen;
#else
   return NULL;
#endif
}