diff options
author | bunnei <bunneidev@gmail.com> | 2018-07-24 03:30:23 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-07-24 03:30:23 +0200 |
commit | f6f6f3811ef0c8ff30134755fadc7222f070c507 (patch) | |
tree | 63122d84de79dd7723d0f475e9bc0aed0db58c02 | |
parent | Merge pull request #780 from lioncash/move (diff) | |
parent | gl_shader_decompiler: Simplify GetCommonDeclarations() (diff) | |
download | yuzu-f6f6f3811ef0c8ff30134755fadc7222f070c507.tar yuzu-f6f6f3811ef0c8ff30134755fadc7222f070c507.tar.gz yuzu-f6f6f3811ef0c8ff30134755fadc7222f070c507.tar.bz2 yuzu-f6f6f3811ef0c8ff30134755fadc7222f070c507.tar.lz yuzu-f6f6f3811ef0c8ff30134755fadc7222f070c507.tar.xz yuzu-f6f6f3811ef0c8ff30134755fadc7222f070c507.tar.zst yuzu-f6f6f3811ef0c8ff30134755fadc7222f070c507.zip |
-rw-r--r-- | src/video_core/renderer_opengl/gl_shader_decompiler.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/video_core/renderer_opengl/gl_shader_decompiler.cpp b/src/video_core/renderer_opengl/gl_shader_decompiler.cpp index ba827181b..e771411ef 100644 --- a/src/video_core/renderer_opengl/gl_shader_decompiler.cpp +++ b/src/video_core/renderer_opengl/gl_shader_decompiler.cpp @@ -6,6 +6,9 @@ #include <set> #include <string> #include <string_view> + +#include <fmt/format.h> + #include "common/assert.h" #include "common/common_types.h" #include "video_core/engines/shader_bytecode.h" @@ -1774,11 +1777,8 @@ private: }; // namespace Decompiler std::string GetCommonDeclarations() { - std::string declarations; - declarations += "#define MAX_CONSTBUFFER_ELEMENTS " + - std::to_string(RasterizerOpenGL::MaxConstbufferSize / (sizeof(GLvec4))); - declarations += '\n'; - return declarations; + return fmt::format("#define MAX_CONSTBUFFER_ELEMENTS {}\n", + RasterizerOpenGL::MaxConstbufferSize / sizeof(GLvec4)); } boost::optional<ProgramResult> DecompileProgram(const ProgramCode& program_code, u32 main_offset, |