Mesa (master): st/xa: stop using cso_set_sampler_views
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Fri Jan 15 10:07:39 UTC 2021
Module: Mesa
Branch: master
Commit: 2a0195f4b9e535945a2df9c16469d923a696126a
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=2a0195f4b9e535945a2df9c16469d923a696126a
Author: Marek Olšák <marek.olsak at amd.com>
Date: Sun Dec 20 00:43:39 2020 -0500
st/xa: stop using cso_set_sampler_views
It will be removed.
Reviewed-by: Eric Anholt <eric at anholt.net>
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer at amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8180>
---
src/gallium/frontends/xa/xa_composite.c | 4 ++--
src/gallium/frontends/xa/xa_context.c | 2 +-
src/gallium/frontends/xa/xa_renderer.c | 2 +-
src/gallium/frontends/xa/xa_yuv.c | 2 +-
4 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/src/gallium/frontends/xa/xa_composite.c b/src/gallium/frontends/xa/xa_composite.c
index 34d78027e27..45bc031e8c0 100644
--- a/src/gallium/frontends/xa/xa_composite.c
+++ b/src/gallium/frontends/xa/xa_composite.c
@@ -504,8 +504,8 @@ bind_samplers(struct xa_context *ctx,
cso_set_samplers(ctx->cso, PIPE_SHADER_FRAGMENT, num_samplers,
(const struct pipe_sampler_state **)samplers);
- cso_set_sampler_views(ctx->cso, PIPE_SHADER_FRAGMENT, num_samplers,
- ctx->bound_sampler_views);
+ pipe->set_sampler_views(pipe, PIPE_SHADER_FRAGMENT, 0, num_samplers,
+ ctx->bound_sampler_views);
ctx->num_bound_samplers = num_samplers;
}
diff --git a/src/gallium/frontends/xa/xa_context.c b/src/gallium/frontends/xa/xa_context.c
index 8593644fb09..dc9586dd4b0 100644
--- a/src/gallium/frontends/xa/xa_context.c
+++ b/src/gallium/frontends/xa/xa_context.c
@@ -327,7 +327,7 @@ xa_solid_prepare(struct xa_context *ctx, struct xa_surface *dst,
renderer_bind_destination(ctx, ctx->srf);
bind_solid_blend_state(ctx);
cso_set_samplers(ctx->cso, PIPE_SHADER_FRAGMENT, 0, NULL);
- cso_set_sampler_views(ctx->cso, PIPE_SHADER_FRAGMENT, 0, NULL);
+ ctx->pipe->set_sampler_views(ctx->pipe, PIPE_SHADER_FRAGMENT, 0, XA_MAX_SAMPLERS, NULL);
shader = xa_shaders_get(ctx->shaders, vs_traits, fs_traits);
cso_set_vertex_shader_handle(ctx->cso, shader.vs);
diff --git a/src/gallium/frontends/xa/xa_renderer.c b/src/gallium/frontends/xa/xa_renderer.c
index 89548ad7019..91d129b0338 100644
--- a/src/gallium/frontends/xa/xa_renderer.c
+++ b/src/gallium/frontends/xa/xa_renderer.c
@@ -442,7 +442,7 @@ renderer_copy_prepare(struct xa_context *r,
u_sampler_view_default_template(&templ,
src_texture, src_texture->format);
src_view = pipe->create_sampler_view(pipe, src_texture, &templ);
- cso_set_sampler_views(r->cso, PIPE_SHADER_FRAGMENT, 1, &src_view);
+ pipe->set_sampler_views(pipe, PIPE_SHADER_FRAGMENT, 0, 1, &src_view);
pipe_sampler_view_reference(&src_view, NULL);
}
diff --git a/src/gallium/frontends/xa/xa_yuv.c b/src/gallium/frontends/xa/xa_yuv.c
index 97a1833ff15..ce49aa23d8b 100644
--- a/src/gallium/frontends/xa/xa_yuv.c
+++ b/src/gallium/frontends/xa/xa_yuv.c
@@ -93,7 +93,7 @@ xa_yuv_bind_samplers(struct xa_context *r, struct xa_surface *yuv[])
}
r->num_bound_samplers = 3;
cso_set_samplers(r->cso, PIPE_SHADER_FRAGMENT, 3, (const struct pipe_sampler_state **)samplers);
- cso_set_sampler_views(r->cso, PIPE_SHADER_FRAGMENT, 3, r->bound_sampler_views);
+ r->pipe->set_sampler_views(r->pipe, PIPE_SHADER_FRAGMENT, 0, 3, r->bound_sampler_views);
}
static void
More information about the mesa-commit
mailing list