mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-01 18:20:10 +01:00
zink: fix zink_format_is_voidable_rgba_variant()
this should just match whatever X formats are emulated Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31277>
This commit is contained in:
parent
42648508f7
commit
f96dc11e41
1 changed files with 1 additions and 19 deletions
|
|
@ -208,25 +208,7 @@ zink_format_emulate_x8(enum pipe_format format)
|
|||
bool
|
||||
zink_format_is_voidable_rgba_variant(enum pipe_format format)
|
||||
{
|
||||
const struct util_format_description *desc = util_format_description(format);
|
||||
unsigned chan;
|
||||
|
||||
if(desc->block.width != 1 ||
|
||||
desc->block.height != 1 ||
|
||||
(desc->block.bits != 32 && desc->block.bits != 64 &&
|
||||
desc->block.bits != 128))
|
||||
return false;
|
||||
|
||||
if (desc->nr_channels != 4)
|
||||
return false;
|
||||
|
||||
unsigned size = desc->channel[0].size;
|
||||
for(chan = 0; chan < 4; ++chan) {
|
||||
if(desc->channel[chan].size != size)
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
return format != zink_format_emulate_x8(format);
|
||||
}
|
||||
|
||||
void
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue