diff options
| author | Tony Wasserka <neobrainx@gmail.com> | 2014-02-04 14:05:55 -0800 |
|---|---|---|
| committer | Tony Wasserka <neobrainx@gmail.com> | 2014-02-04 14:05:55 -0800 |
| commit | af24ed782d263ea20cd82107c4119ffe81fe1780 (patch) | |
| tree | 27a90ffb172eaf49b6e202274b29edad9b099eb4 /Source/Core/VideoCommon/VertexShaderGen.cpp | |
| parent | 00089433a6ce1ea4262eb86a7e206f1953a3f3b9 (diff) | |
| parent | 6089e4470ab2636c9c8d697905ee79135e33072f (diff) | |
Merge pull request #14 from degasus/uboWorkaroundRemove
OGL: Remove non-UBO code path.
Diffstat (limited to 'Source/Core/VideoCommon/VertexShaderGen.cpp')
| -rw-r--r-- | Source/Core/VideoCommon/VertexShaderGen.cpp | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/Source/Core/VideoCommon/VertexShaderGen.cpp b/Source/Core/VideoCommon/VertexShaderGen.cpp index b805b0459a..5d1855d8d9 100644 --- a/Source/Core/VideoCommon/VertexShaderGen.cpp +++ b/Source/Core/VideoCommon/VertexShaderGen.cpp @@ -83,20 +83,20 @@ static inline void GenerateVertexShader(T& out, u32 components, API_TYPE api_typ _assert_(bpmem.genMode.numcolchans == xfregs.numChan.numColorChans); // uniforms - if (g_ActiveConfig.backend_info.bSupportsGLSLUBO) + if (api_type == API_OPENGL) out.Write("layout(std140%s) uniform VSBlock {\n", g_ActiveConfig.backend_info.bSupportShadingLanguage420pack ? ", binding = 2" : ""); - DeclareUniform(out, api_type, g_ActiveConfig.backend_info.bSupportsGLSLUBO, C_POSNORMALMATRIX, "float4", I_POSNORMALMATRIX"[6]"); - DeclareUniform(out, api_type, g_ActiveConfig.backend_info.bSupportsGLSLUBO, C_PROJECTION, "float4", I_PROJECTION"[4]"); - DeclareUniform(out, api_type, g_ActiveConfig.backend_info.bSupportsGLSLUBO, C_MATERIALS, "float4", I_MATERIALS"[4]"); - DeclareUniform(out, api_type, g_ActiveConfig.backend_info.bSupportsGLSLUBO, C_LIGHTS, "float4", I_LIGHTS"[40]"); - DeclareUniform(out, api_type, g_ActiveConfig.backend_info.bSupportsGLSLUBO, C_TEXMATRICES, "float4", I_TEXMATRICES"[24]"); - DeclareUniform(out, api_type, g_ActiveConfig.backend_info.bSupportsGLSLUBO, C_TRANSFORMMATRICES, "float4", I_TRANSFORMMATRICES"[64]"); - DeclareUniform(out, api_type, g_ActiveConfig.backend_info.bSupportsGLSLUBO, C_NORMALMATRICES, "float4", I_NORMALMATRICES"[32]"); - DeclareUniform(out, api_type, g_ActiveConfig.backend_info.bSupportsGLSLUBO, C_POSTTRANSFORMMATRICES, "float4", I_POSTTRANSFORMMATRICES"[64]"); - DeclareUniform(out, api_type, g_ActiveConfig.backend_info.bSupportsGLSLUBO, C_DEPTHPARAMS, "float4", I_DEPTHPARAMS); - - if (g_ActiveConfig.backend_info.bSupportsGLSLUBO) + DeclareUniform(out, api_type, C_POSNORMALMATRIX, "float4", I_POSNORMALMATRIX"[6]"); + DeclareUniform(out, api_type, C_PROJECTION, "float4", I_PROJECTION"[4]"); + DeclareUniform(out, api_type, C_MATERIALS, "float4", I_MATERIALS"[4]"); + DeclareUniform(out, api_type, C_LIGHTS, "float4", I_LIGHTS"[40]"); + DeclareUniform(out, api_type, C_TEXMATRICES, "float4", I_TEXMATRICES"[24]"); + DeclareUniform(out, api_type, C_TRANSFORMMATRICES, "float4", I_TRANSFORMMATRICES"[64]"); + DeclareUniform(out, api_type, C_NORMALMATRICES, "float4", I_NORMALMATRICES"[32]"); + DeclareUniform(out, api_type, C_POSTTRANSFORMMATRICES, "float4", I_POSTTRANSFORMMATRICES"[64]"); + DeclareUniform(out, api_type, C_DEPTHPARAMS, "float4", I_DEPTHPARAMS); + + if (api_type == API_OPENGL) out.Write("};\n"); GenerateVSOutputStruct(out, api_type); |
