diff options
| author | 2021-05-26 00:16:20 -0400 | |
|---|---|---|
| committer | 2021-07-22 21:51:36 -0400 | |
| commit | 3d086e6130a2c5f0546ccef3b234c65ef2f0c99b (patch) | |
| tree | eaddf938c32f9a077ff671db4e9ebe9634304033 /src/shader_recompiler/backend/glsl/emit_context.h | |
| parent | glsl: Track S32 atomics (diff) | |
| download | yuzu-3d086e6130a2c5f0546ccef3b234c65ef2f0c99b.tar.gz yuzu-3d086e6130a2c5f0546ccef3b234c65ef2f0c99b.tar.xz yuzu-3d086e6130a2c5f0546ccef3b234c65ef2f0c99b.zip | |
glsl: Implement some attribute getters and setters
Diffstat (limited to 'src/shader_recompiler/backend/glsl/emit_context.h')
| -rw-r--r-- | src/shader_recompiler/backend/glsl/emit_context.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/shader_recompiler/backend/glsl/emit_context.h b/src/shader_recompiler/backend/glsl/emit_context.h index 7f8857fa7..087eaff6a 100644 --- a/src/shader_recompiler/backend/glsl/emit_context.h +++ b/src/shader_recompiler/backend/glsl/emit_context.h | |||
| @@ -89,6 +89,11 @@ public: | |||
| 89 | } | 89 | } |
| 90 | 90 | ||
| 91 | template <typename... Args> | 91 | template <typename... Args> |
| 92 | void AddF32x4(const char* format_str, IR::Inst& inst, Args&&... args) { | ||
| 93 | Add<Type::F32x4>(format_str, inst, args...); | ||
| 94 | } | ||
| 95 | |||
| 96 | template <typename... Args> | ||
| 92 | void Add(const char* format_str, Args&&... args) { | 97 | void Add(const char* format_str, Args&&... args) { |
| 93 | code += fmt::format(format_str, std::forward<Args>(args)...); | 98 | code += fmt::format(format_str, std::forward<Args>(args)...); |
| 94 | // TODO: Remove this | 99 | // TODO: Remove this |
| @@ -100,6 +105,10 @@ public: | |||
| 100 | const Info& info; | 105 | const Info& info; |
| 101 | const Profile& profile; | 106 | const Profile& profile; |
| 102 | 107 | ||
| 108 | Stage stage{}; | ||
| 109 | std::string_view stage_name = "invalid"; | ||
| 110 | std::string_view attrib_name = "invalid"; | ||
| 111 | |||
| 103 | private: | 112 | private: |
| 104 | void SetupExtensions(std::string& header); | 113 | void SetupExtensions(std::string& header); |
| 105 | void DefineConstantBuffers(); | 114 | void DefineConstantBuffers(); |