Exemplo n.º 1
0
static struct pipe_resource *
rbug_screen_resource_create(struct pipe_screen *_screen,
                            const struct pipe_resource *templat)
{
   struct rbug_screen *rb_screen = rbug_screen(_screen);
   struct pipe_screen *screen = rb_screen->screen;
   struct pipe_resource *result;

   result = screen->resource_create(screen,
                                    templat);

   if (result)
      return rbug_resource_create(rb_screen, result);
   return NULL;
}
Exemplo n.º 2
0
static struct pipe_resource *
rbug_screen_resource_from_handle(struct pipe_screen *_screen,
                                 const struct pipe_resource *templ,
                                 struct winsys_handle *handle)
{
   struct rbug_screen *rb_screen = rbug_screen(_screen);
   struct pipe_screen *screen = rb_screen->screen;
   struct pipe_resource *result;

   result = screen->resource_from_handle(screen, templ, handle);

   result = rbug_resource_create(rbug_screen(_screen), result);

   return result;
}
Exemplo n.º 3
0
static struct pipe_resource *
rbug_screen_user_buffer_create(struct pipe_screen *_screen,
                               void *ptr,
                               unsigned bytes,
                               unsigned usage)
{
   struct rbug_screen *rb_screen = rbug_screen(_screen);
   struct pipe_screen *screen = rb_screen->screen;
   struct pipe_resource *result;

   result = screen->user_buffer_create(screen,
                                       ptr,
                                       bytes,
                                       usage);

   if (result)
      return rbug_resource_create(rb_screen, result);
   return NULL;
}