r600/sfn: Handle number of color outputs taking dual source blending into account
Signed-off-by: Gert Wollny <gert.wollny@collabora.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6814>
This commit is contained in:
@@ -284,14 +284,14 @@ void FragmentShaderFromNir::emit_shader_start()
|
||||
bool FragmentShaderFromNir::do_emit_store_deref(const nir_variable *out_var, nir_intrinsic_instr* instr)
|
||||
{
|
||||
if (out_var->data.location == FRAG_RESULT_COLOR)
|
||||
return emit_export_pixel(out_var, instr, true);
|
||||
return emit_export_pixel(out_var, instr, m_dual_source_blend ? 1 : m_max_color_exports);
|
||||
|
||||
if ((out_var->data.location >= FRAG_RESULT_DATA0 &&
|
||||
out_var->data.location <= FRAG_RESULT_DATA7) ||
|
||||
out_var->data.location == FRAG_RESULT_DEPTH ||
|
||||
out_var->data.location == FRAG_RESULT_STENCIL ||
|
||||
out_var->data.location == FRAG_RESULT_SAMPLE_MASK)
|
||||
return emit_export_pixel(out_var, instr, false);
|
||||
return emit_export_pixel(out_var, instr, 1);
|
||||
|
||||
sfn_log << SfnLog::err << "r600-NIR: Unimplemented store_deref for " <<
|
||||
out_var->data.location << "(" << out_var->data.driver_location << ")\n";
|
||||
|
@@ -54,7 +54,7 @@ private:
|
||||
bool do_process_outputs(nir_variable *output) override;
|
||||
bool do_emit_load_deref(const nir_variable *in_var, nir_intrinsic_instr* instr) override;
|
||||
bool do_emit_store_deref(const nir_variable *out_var, nir_intrinsic_instr* instr) override;
|
||||
bool emit_export_pixel(const nir_variable *, nir_intrinsic_instr* instr, bool all_chanels);
|
||||
bool emit_export_pixel(const nir_variable *, nir_intrinsic_instr* instr, int outputs);
|
||||
bool load_interpolated(GPRVector &dest, ShaderInput &io, const Interpolator& ip,
|
||||
int num_components, int start_comp);
|
||||
bool load_interpolated_one_comp(GPRVector &dest, ShaderInput& io, const Interpolator& ip, EAluOp op);
|
||||
|
Reference in New Issue
Block a user