From e6b2212ec0240c8d00ec2f72b84c037db94bfccb Mon Sep 17 00:00:00 2001 From: Stenzek Date: Tue, 29 Mar 2016 13:35:16 +1000 Subject: ShaderGen: Only specify storage qualifier in interface block when needed Drivers that don't support GL_ARB_shading_language_420pack require that the storage qualifier be specified even when inside an interface block. AMD's driver throws a compile error when "centroid in/out" is used within an interface block. Our previous behavior was to include the storage qualifier regardless, but this wasn't working on AMD, therefore we should check for the presence of the extension and include based on this, instead. --- Source/Core/VideoCommon/PixelShaderGen.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'Source/Core/VideoCommon/PixelShaderGen.cpp') diff --git a/Source/Core/VideoCommon/PixelShaderGen.cpp b/Source/Core/VideoCommon/PixelShaderGen.cpp index cc0ab52422..5ae79e0733 100644 --- a/Source/Core/VideoCommon/PixelShaderGen.cpp +++ b/Source/Core/VideoCommon/PixelShaderGen.cpp @@ -354,12 +354,11 @@ static T GeneratePixelShader(DSTALPHA_MODE dstAlphaMode, API_TYPE ApiType) uid_data->stereo = g_ActiveConfig.iStereoMode > 0; if (g_ActiveConfig.backend_info.bSupportsGeometryShaders) { - out.Write("// The interface block qualifier is duplicated to its member due to Apple OS X bug 24983074\n"); out.Write("in VertexData {\n"); - GenerateVSOutputMembers(out, ApiType, "in", GetInterpolationQualifier()); + GenerateVSOutputMembers(out, ApiType, GetInterpolationQualifier(true, true)); if (g_ActiveConfig.iStereoMode > 0) - out.Write("\tflat in int layer;\n"); + out.Write("\tflat int layer;\n"); out.Write("};\n"); } -- cgit v1.2.3