mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 20:28:04 +02:00
etnaviv: don't use int filter for depth textures
The int filter has precision issues when used with depth textures, causing failures in tests like piglit spec@arb_depth_texture@fbo-depth-gl_depth_component16-drawpixels. In addition to that the texture compare unit for GL_ARB_shadow operations seems to be only implemented in the float filter pipe, so this change also fixes this functionality on GPUs where it isn't emulated, e.g. GC3000. Signed-off-by: Lucas Stach <l.stach@pengutronix.de> Reviewed-by: Christian Gmeiner <cgmeiner@igalia.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28218>
This commit is contained in:
parent
5464feed73
commit
c6a6160583
1 changed files with 3 additions and 2 deletions
|
|
@ -292,6 +292,9 @@ texture_use_int_filter(const struct pipe_sampler_view *sv,
|
|||
if (util_format_is_srgb(sv->format))
|
||||
return false;
|
||||
|
||||
if (util_format_is_depth_or_stencil(sv->format))
|
||||
return false;
|
||||
|
||||
if (util_format_description(sv->format)->layout == UTIL_FORMAT_LAYOUT_ASTC)
|
||||
return false;
|
||||
|
||||
|
|
@ -299,8 +302,6 @@ texture_use_int_filter(const struct pipe_sampler_view *sv,
|
|||
return false;
|
||||
|
||||
switch (sv->format) {
|
||||
/* apparently D16 can't use int filter but D24 can */
|
||||
case PIPE_FORMAT_Z16_UNORM:
|
||||
case PIPE_FORMAT_R10G10B10A2_UNORM:
|
||||
case PIPE_FORMAT_R10G10B10X2_UNORM:
|
||||
case PIPE_FORMAT_ETC2_R11_UNORM:
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue