diff options
author | bunnei <bunneidev@gmail.com> | 2018-04-14 21:57:58 +0200 |
---|---|---|
committer | bunnei <bunneidev@gmail.com> | 2018-04-14 22:01:41 +0200 |
commit | e6224fec275a725bfbb261003c9db44a3da475df (patch) | |
tree | fe71eabcb16f765a3dbf107d8b7dca9dfde854f0 /src/video_core/renderer_opengl/gl_shader_decompiler.cpp | |
parent | gl_shader_decompiler: Cleanup log statements. (diff) | |
download | yuzu-e6224fec275a725bfbb261003c9db44a3da475df.tar yuzu-e6224fec275a725bfbb261003c9db44a3da475df.tar.gz yuzu-e6224fec275a725bfbb261003c9db44a3da475df.tar.bz2 yuzu-e6224fec275a725bfbb261003c9db44a3da475df.tar.lz yuzu-e6224fec275a725bfbb261003c9db44a3da475df.tar.xz yuzu-e6224fec275a725bfbb261003c9db44a3da475df.tar.zst yuzu-e6224fec275a725bfbb261003c9db44a3da475df.zip |
Diffstat (limited to '')
-rw-r--r-- | src/video_core/renderer_opengl/gl_shader_decompiler.cpp | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/src/video_core/renderer_opengl/gl_shader_decompiler.cpp b/src/video_core/renderer_opengl/gl_shader_decompiler.cpp index 6251a4be2..1290fa4cd 100644 --- a/src/video_core/renderer_opengl/gl_shader_decompiler.cpp +++ b/src/video_core/renderer_opengl/gl_shader_decompiler.cpp @@ -448,17 +448,19 @@ private: for (const auto& index : declr_input_attribute) { // TODO(bunnei): Use proper number of elements for these - declarations.AddLine( - "layout(location = " + std::to_string(static_cast<u32>(index) - 8) + ") in vec4 " + - GetInputAttribute(index) + ";"); + declarations.AddLine("layout(location = " + + std::to_string(static_cast<u32>(index) - + static_cast<u32>(Attribute::Index::Attribute_0)) + + ") in vec4 " + GetInputAttribute(index) + ";"); } declarations.AddLine(""); for (const auto& index : declr_output_attribute) { // TODO(bunnei): Use proper number of elements for these - declarations.AddLine( - "layout(location = " + std::to_string(static_cast<u32>(index) - 8) + ") out vec4 " + - GetOutputAttribute(index) + ";"); + declarations.AddLine("layout(location = " + + std::to_string(static_cast<u32>(index) - + static_cast<u32>(Attribute::Index::Attribute_0)) + + ") out vec4 " + GetOutputAttribute(index) + ";"); } declarations.AddLine(""); } |