gallium/vl: Create sampler state also when gfx is not supported

This is also used by compute shaders.

Cc: mesa-stable
Reviewed-by: Leo Liu <leo.liu@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32794>
This commit is contained in:
David Rosca
2025-01-01 12:48:30 +01:00
committed by Marge Bot
parent d79fa22801
commit 38979d3b4d

View File

@@ -155,14 +155,13 @@ init_pipe_state(struct vl_compositor *c)
sampler.mag_img_filter = PIPE_TEX_FILTER_LINEAR;
sampler.compare_mode = PIPE_TEX_COMPARE_NONE;
sampler.compare_func = PIPE_FUNC_ALWAYS;
c->sampler_linear = c->pipe->create_sampler_state(c->pipe, &sampler);
sampler.min_img_filter = PIPE_TEX_FILTER_NEAREST;
sampler.mag_img_filter = PIPE_TEX_FILTER_NEAREST;
c->sampler_nearest = c->pipe->create_sampler_state(c->pipe, &sampler);
if (c->pipe_gfx_supported) {
c->sampler_linear = c->pipe->create_sampler_state(c->pipe, &sampler);
sampler.min_img_filter = PIPE_TEX_FILTER_NEAREST;
sampler.mag_img_filter = PIPE_TEX_FILTER_NEAREST;
c->sampler_nearest = c->pipe->create_sampler_state(c->pipe, &sampler);
memset(&blend, 0, sizeof blend);
blend.independent_blend_enable = 0;
blend.rt[0].blend_enable = 0;