aboutsummaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/r600/sfn/sfn_shader_tcs.h
blob: ba914a75373a8e3d3a90168c84890dd7e2b1f928 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#ifndef TCSSHADERFROMNIR_H
#define TCSSHADERFROMNIR_H

#include "sfn_shader_base.h"

namespace r600 {

class TcsShaderFromNir : public ShaderFromNirProcessor
{
public:
   TcsShaderFromNir(r600_pipe_shader *sh, r600_pipe_shader_selector& sel, const r600_shader_key& key, enum chip_class chip_class);
   bool scan_sysvalue_access(nir_instr *instr) override;

private:
   bool do_allocate_reserved_registers() override;
   bool emit_intrinsic_instruction_override(nir_intrinsic_instr* instr) override;
   bool store_tess_factor(nir_intrinsic_instr* instr);

   bool do_process_inputs(nir_variable *input) override { return true;}
   bool do_process_outputs(nir_variable *output) override;
   bool do_emit_load_deref(const nir_variable *in_var, nir_intrinsic_instr* instr) override { return true;}
   bool do_emit_store_deref(const nir_variable *out_var, nir_intrinsic_instr* instr) override { return true;}
   void do_finalize() override {}

   int m_reserved_registers;
   PValue m_patch_id;
   PValue m_rel_patch_id;
   PValue m_invocation_id;
   PValue m_primitive_id;
   PValue m_tess_factor_base;


};

}

#endif // TCSSHADERFROMNIR_H