summaryrefslogtreecommitdiffstats
path: root/src/shader_recompiler/backend/glasm/emit_context.cpp
diff options
context:
space:
mode:
authorReinUsesLisp <reinuseslisp@airmail.cc>2021-05-20 07:18:52 +0200
committerameerj <52414509+ameerj@users.noreply.github.com>2021-07-23 03:51:32 +0200
commitdadd192b30d547dfa078057796a5ae16820eb4be (patch)
treeba7188229572a9001b6f49db53b4dd332e617ffb /src/shader_recompiler/backend/glasm/emit_context.cpp
parentglasm: Implement EmitVertex and EndPrimitive (diff)
downloadyuzu-dadd192b30d547dfa078057796a5ae16820eb4be.tar
yuzu-dadd192b30d547dfa078057796a5ae16820eb4be.tar.gz
yuzu-dadd192b30d547dfa078057796a5ae16820eb4be.tar.bz2
yuzu-dadd192b30d547dfa078057796a5ae16820eb4be.tar.lz
yuzu-dadd192b30d547dfa078057796a5ae16820eb4be.tar.xz
yuzu-dadd192b30d547dfa078057796a5ae16820eb4be.tar.zst
yuzu-dadd192b30d547dfa078057796a5ae16820eb4be.zip
Diffstat (limited to 'src/shader_recompiler/backend/glasm/emit_context.cpp')
-rw-r--r--src/shader_recompiler/backend/glasm/emit_context.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/shader_recompiler/backend/glasm/emit_context.cpp b/src/shader_recompiler/backend/glasm/emit_context.cpp
index 463930a18..8f418936e 100644
--- a/src/shader_recompiler/backend/glasm/emit_context.cpp
+++ b/src/shader_recompiler/backend/glasm/emit_context.cpp
@@ -82,6 +82,16 @@ EmitContext::EmitContext(IR::Program& program, Bindings& bindings, const Profile
Add("OUTPUT out_attr{}[]={{result.attrib[{}..{}]}};", index, index, index);
}
}
+ image_buffer_bindings.reserve(program.info.image_buffer_descriptors.size());
+ for (const auto& desc : program.info.image_buffer_descriptors) {
+ image_buffer_bindings.push_back(bindings.image);
+ bindings.image += desc.count;
+ }
+ image_bindings.reserve(program.info.image_descriptors.size());
+ for (const auto& desc : program.info.image_descriptors) {
+ image_bindings.push_back(bindings.image);
+ bindings.image += desc.count;
+ }
texture_buffer_bindings.reserve(program.info.texture_buffer_descriptors.size());
for (const auto& desc : program.info.texture_buffer_descriptors) {
texture_buffer_bindings.push_back(bindings.texture);