diff options
author | ameerj <52414509+ameerj@users.noreply.github.com> | 2021-05-31 04:42:52 +0200 |
---|---|---|
committer | ameerj <52414509+ameerj@users.noreply.github.com> | 2021-07-23 03:51:37 +0200 |
commit | 14bfb4719ad366745b5d16452914c4c78e43b8ae (patch) | |
tree | 16e61490f8263f80574a73e2bef2a4aebde6b634 /src/shader_recompiler/backend/glsl/emit_glsl.cpp | |
parent | glsl: Fix ssbo indexing and name shadowing between shader stages (diff) | |
download | yuzu-14bfb4719ad366745b5d16452914c4c78e43b8ae.tar yuzu-14bfb4719ad366745b5d16452914c4c78e43b8ae.tar.gz yuzu-14bfb4719ad366745b5d16452914c4c78e43b8ae.tar.bz2 yuzu-14bfb4719ad366745b5d16452914c4c78e43b8ae.tar.lz yuzu-14bfb4719ad366745b5d16452914c4c78e43b8ae.tar.xz yuzu-14bfb4719ad366745b5d16452914c4c78e43b8ae.tar.zst yuzu-14bfb4719ad366745b5d16452914c4c78e43b8ae.zip |
Diffstat (limited to 'src/shader_recompiler/backend/glsl/emit_glsl.cpp')
-rw-r--r-- | src/shader_recompiler/backend/glsl/emit_glsl.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/shader_recompiler/backend/glsl/emit_glsl.cpp b/src/shader_recompiler/backend/glsl/emit_glsl.cpp index f0257db7f..19cf4e46b 100644 --- a/src/shader_recompiler/backend/glsl/emit_glsl.cpp +++ b/src/shader_recompiler/backend/glsl/emit_glsl.cpp @@ -209,6 +209,12 @@ std::string EmitGLSL(const Profile& profile, const RuntimeInfo& runtime_info, IR ctx.header += "void main(){\n"; if (program.stage == Stage::VertexA || program.stage == Stage::VertexB) { ctx.header += "gl_Position = vec4(0.0f, 0.0f, 0.0f, 1.0f);"; + // TODO: Properly resolve attribute issues + for (size_t index = 0; index < program.info.stores_generics.size() / 2; ++index) { + if (!program.info.stores_generics[index]) { + ctx.header += fmt::format("out_attr{}=vec4(0,0,0,1);", index); + } + } } DefineVariables(ctx, ctx.header); if (ctx.uses_cc_carry) { |