mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-07 17:58:26 +02:00
zink: Fix validation failure for maxLod < minLod.
GL lets you set a silly state, so do something plausible instead of
undefined.
Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20756>
(cherry picked from commit adf81044d4)
This commit is contained in:
parent
4671e270df
commit
617fdb8818
2 changed files with 2 additions and 2 deletions
|
|
@ -805,7 +805,7 @@
|
|||
"description": "zink: Fix validation failure for maxLod < minLod.",
|
||||
"nominated": true,
|
||||
"nomination_type": 0,
|
||||
"resolution": 0,
|
||||
"resolution": 1,
|
||||
"main_sha": null,
|
||||
"because_sha": null
|
||||
},
|
||||
|
|
|
|||
|
|
@ -369,7 +369,7 @@ zink_create_sampler_state(struct pipe_context *pctx,
|
|||
} else if (state->min_mip_filter != PIPE_TEX_MIPFILTER_NONE) {
|
||||
sci.mipmapMode = sampler_mipmap_mode(state->min_mip_filter);
|
||||
sci.minLod = state->min_lod;
|
||||
sci.maxLod = state->max_lod;
|
||||
sci.maxLod = MAX2(state->max_lod, state->min_lod);
|
||||
} else {
|
||||
sci.mipmapMode = VK_SAMPLER_MIPMAP_MODE_NEAREST;
|
||||
sci.minLod = 0;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue