mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-08 02:38:04 +02:00
svga: stop using pipe_context::create_surface()
Call svga_create_surface() directly instead. Signed-off-by: Brian Paul <brian.paul@broadcom.com> Reviewed-by: Neha Bhende <neha.bhende@broadcom.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/35565>
This commit is contained in:
parent
8d13fc447e
commit
21a83aba3b
4 changed files with 9 additions and 4 deletions
|
|
@ -278,7 +278,7 @@ svga_clear_texture(struct pipe_context *pipe,
|
|||
tmpl.last_layer = box->z + box->depth - 1;
|
||||
tmpl.level = level;
|
||||
|
||||
surface = pipe->create_surface(pipe, res, &tmpl);
|
||||
surface = svga_create_surface(pipe, res, &tmpl);
|
||||
if (surface == NULL) {
|
||||
debug_printf("failed to create surface\n");
|
||||
return;
|
||||
|
|
|
|||
|
|
@ -110,7 +110,7 @@ svga_copy_framebuffer_state(struct svga_context *svga,
|
|||
}
|
||||
|
||||
struct pipe_surface *psurf = src->cbufs[i].texture
|
||||
? pctx->create_surface(pctx, src->cbufs[i].texture, &src->cbufs[i])
|
||||
? svga_create_surface(pctx, src->cbufs[i].texture, &src->cbufs[i])
|
||||
: NULL;
|
||||
if (dst->cbufs[i]) {
|
||||
svga_surface_unref(pctx, &dst->cbufs[i]);
|
||||
|
|
@ -134,7 +134,7 @@ svga_copy_framebuffer_state(struct svga_context *svga,
|
|||
}
|
||||
|
||||
struct pipe_surface *psurf = src->zsbuf.texture
|
||||
? pctx->create_surface(pctx, src->zsbuf.texture, &src->zsbuf)
|
||||
? svga_create_surface(pctx, src->zsbuf.texture, &src->zsbuf)
|
||||
: NULL;
|
||||
if (dst->zsbuf) {
|
||||
svga_surface_unref(pctx, &dst->zsbuf);
|
||||
|
|
|
|||
|
|
@ -402,7 +402,7 @@ done:
|
|||
}
|
||||
|
||||
|
||||
static struct pipe_surface *
|
||||
struct pipe_surface *
|
||||
svga_create_surface(struct pipe_context *pipe,
|
||||
struct pipe_resource *pt,
|
||||
const struct pipe_surface *surf_tmpl)
|
||||
|
|
|
|||
|
|
@ -135,6 +135,11 @@ svga_texture_copy_handle(struct svga_context *svga,
|
|||
unsigned width, unsigned height, unsigned depth);
|
||||
|
||||
|
||||
struct pipe_surface *
|
||||
svga_create_surface(struct pipe_context *pipe,
|
||||
struct pipe_resource *pt,
|
||||
const struct pipe_surface *surf_tmpl);
|
||||
|
||||
static inline struct svga_surface *
|
||||
svga_surface(struct pipe_surface *surface)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue