mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-06-12 09:38:20 +02:00
st/mesa: align cube map arrays layers
We create textures internally for texsubimage, and we use
the values from sub image to create a new texture, however
we don't align these to valid sizes, and cube map arrays
must have an array size aligned to 6.
This fixes texsubimage cube_map_array on CAYMAN at least,
(it was causing GPU hang and bad values), it probably
also fixes it on radeonsi and evergreen.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=89957
Tested-by: Tom Stellard <thomas.stellard@amd.com>
Cc: mesa-stable@lists.freedesktop.org
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
(cherry picked from commit cc5860e407)
This commit is contained in:
parent
b2a6b01082
commit
f44e518364
1 changed files with 1 additions and 1 deletions
|
|
@ -177,7 +177,7 @@ st_gl_texture_dims_to_pipe_dims(GLenum texture,
|
|||
*widthOut = widthIn;
|
||||
*heightOut = heightIn;
|
||||
*depthOut = 1;
|
||||
*layersOut = depthIn;
|
||||
*layersOut = util_align_npot(depthIn, 6);
|
||||
break;
|
||||
default:
|
||||
assert(0 && "Unexpected texture in st_gl_texture_dims_to_pipe_dims()");
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue