mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-24 21:50:12 +01:00
pan/bi: Passthrough blend types
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com> Signed-off-by: Tomeu Vizoso <tomeu.vizoso@collabora.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4766>
This commit is contained in:
parent
5f953b8f50
commit
1a8f1a324a
3 changed files with 9 additions and 0 deletions
|
|
@ -163,6 +163,10 @@ bi_emit_frag_out(bi_context *ctx, nir_intrinsic_instr *instr)
|
|||
.writemask = 0xF
|
||||
};
|
||||
|
||||
assert(blend.blend_location < 8);
|
||||
assert(ctx->blend_types);
|
||||
ctx->blend_types[blend.blend_location] = blend.src_types[0];
|
||||
|
||||
bi_emit(ctx, blend);
|
||||
bi_schedule_barrier(ctx);
|
||||
}
|
||||
|
|
@ -1074,6 +1078,7 @@ bifrost_compile_shader_nir(nir_shader *nir, panfrost_program *program, unsigned
|
|||
panfrost_nir_assign_sysvals(&ctx->sysvals, nir);
|
||||
program->sysval_count = ctx->sysvals.sysval_count;
|
||||
memcpy(program->sysvals, ctx->sysvals.sysvals, sizeof(ctx->sysvals.sysvals[0]) * ctx->sysvals.sysval_count);
|
||||
ctx->blend_types = program->blend_types;
|
||||
|
||||
nir_foreach_function(func, nir) {
|
||||
if (!func->impl)
|
||||
|
|
|
|||
|
|
@ -387,6 +387,7 @@ typedef struct {
|
|||
bi_block *break_block;
|
||||
bi_block *continue_block;
|
||||
bool emitted_atest;
|
||||
nir_alu_type *blend_types;
|
||||
|
||||
/* For creating temporaries */
|
||||
unsigned temp_alloc;
|
||||
|
|
|
|||
|
|
@ -86,6 +86,9 @@ typedef struct {
|
|||
int work_register_count;
|
||||
int uniform_cutoff;
|
||||
|
||||
/* For Bifrost - output type for each RT */
|
||||
nir_alu_type blend_types[8];
|
||||
|
||||
/* Prepended before uniforms, mapping to SYSVAL_ names for the
|
||||
* sysval */
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue