mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 07:28:11 +02:00
panfrost: Pass through alpha_zero_nop/one_store
Compute whether these flags can be set when constructing the blend CSO and pass them in the appropriate place in the Internal Blend Descriptor. Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com> Acked-by: Boris Brezillon <boris.brezillon@collabora.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13508>
This commit is contained in:
parent
169aa9f177
commit
77928e45eb
2 changed files with 11 additions and 1 deletions
|
|
@ -40,6 +40,8 @@ struct pan_blend_info {
|
|||
bool no_colour : 1;
|
||||
bool load_dest : 1;
|
||||
bool opaque : 1;
|
||||
bool alpha_zero_nop : 1;
|
||||
bool alpha_one_store : 1;
|
||||
};
|
||||
|
||||
struct panfrost_blend_state {
|
||||
|
|
|
|||
|
|
@ -359,6 +359,11 @@ panfrost_emit_blend(struct panfrost_batch *batch, void *rts, mali_ptr *blend_sha
|
|||
cfg.fixed_function.conversion.register_format =
|
||||
fs->info.bifrost.blend[i].format;
|
||||
cfg.fixed_function.rt = i;
|
||||
|
||||
if (!info.opaque) {
|
||||
cfg.fixed_function.alpha_zero_nop = info.alpha_zero_nop;
|
||||
cfg.fixed_function.alpha_one_store = info.alpha_one_store;
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
|
@ -3468,7 +3473,10 @@ panfrost_create_blend_state(struct pipe_context *pipe,
|
|||
pan_blend_can_fixed_function(equation,
|
||||
supports_2src) &&
|
||||
(!constant_mask ||
|
||||
pan_blend_supports_constant(PAN_ARCH, c))
|
||||
pan_blend_supports_constant(PAN_ARCH, c)),
|
||||
|
||||
.alpha_zero_nop = pan_blend_alpha_zero_nop(equation),
|
||||
.alpha_one_store = pan_blend_alpha_one_store(equation),
|
||||
};
|
||||
|
||||
so->pan.rts[c].equation = equation;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue