mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-06-05 15:08:15 +02:00
softpipe: fix depth texture sampling regression
We need to keep using the pipe_get_tile_swizzle() even though there's no swizzling because we need to explicitly pass in the surface format. Fixes http://bugs.freedesktop.org/show_bug.cgi?id=32459
This commit is contained in:
parent
3ecf47af12
commit
9d9f8aba0a
1 changed files with 17 additions and 9 deletions
|
|
@ -278,15 +278,23 @@ sp_find_cached_tile_tex(struct softpipe_tex_tile_cache *tc,
|
|||
tc->tex_z = addr.bits.z;
|
||||
}
|
||||
|
||||
/* get tile from the transfer (view into texture) */
|
||||
pipe_get_tile_rgba(tc->pipe,
|
||||
tc->tex_trans,
|
||||
addr.bits.x * TILE_SIZE,
|
||||
addr.bits.y * TILE_SIZE,
|
||||
TILE_SIZE,
|
||||
TILE_SIZE,
|
||||
(float *) tile->data.color);
|
||||
|
||||
/* get tile from the transfer (view into texture)
|
||||
* Note we're using the swizzle version of this fuction only because
|
||||
* we need to pass the texture cache's format explicitly.
|
||||
*/
|
||||
pipe_get_tile_swizzle(tc->pipe,
|
||||
tc->tex_trans,
|
||||
addr.bits.x * TILE_SIZE,
|
||||
addr.bits.y * TILE_SIZE,
|
||||
TILE_SIZE,
|
||||
TILE_SIZE,
|
||||
PIPE_SWIZZLE_RED,
|
||||
PIPE_SWIZZLE_GREEN,
|
||||
PIPE_SWIZZLE_BLUE,
|
||||
PIPE_SWIZZLE_ALPHA,
|
||||
tc->format,
|
||||
(float *) tile->data.color);
|
||||
|
||||
tile->addr = addr;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue