From 00645ea01ce9f6a8ad278e05f858535670c6e6a4 Mon Sep 17 00:00:00 2001 From: Dave Airlie Date: Tue, 27 Nov 2018 13:02:03 +1000 Subject: [PATCH] iris: fix cube texture view --- src/gallium/drivers/iris/iris_state.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/gallium/drivers/iris/iris_state.c b/src/gallium/drivers/iris/iris_state.c index e07bd8919db..675037a5162 100644 --- a/src/gallium/drivers/iris/iris_state.c +++ b/src/gallium/drivers/iris/iris_state.c @@ -1518,6 +1518,10 @@ iris_create_sampler_view(struct pipe_context *ctx, ISL_SURF_USAGE_TEXTURE_BIT | (isv->res->surf.usage & ISL_SURF_USAGE_CUBE_BIT); + if (isv->base.target == PIPE_TEXTURE_CUBE || + isv->base.target == PIPE_TEXTURE_CUBE_ARRAY) + usage |= ISL_SURF_USAGE_CUBE_BIT; + const struct iris_format_info fmt = iris_format_for_usage(devinfo, tmpl->format, usage); -- 2.30.2