From 002ff4e4dd594c75898df9ba5ee4a14bc8fb7f77 Mon Sep 17 00:00:00 2001 From: Pokechu22 Date: Sat, 17 Apr 2021 09:57:16 -0700 Subject: [PATCH] PixelShaderGen: Remove unused num_texgens argument It became unused in f039149198657c1891e1c6462ed30c31ed4b8486. --- Source/Core/VideoCommon/PixelShaderGen.cpp | 5 ++--- Source/Core/VideoCommon/PixelShaderGen.h | 2 +- Source/Core/VideoCommon/UberShaderPixel.cpp | 2 +- 3 files changed, 4 insertions(+), 5 deletions(-) diff --git a/Source/Core/VideoCommon/PixelShaderGen.cpp b/Source/Core/VideoCommon/PixelShaderGen.cpp index 866b7bacc8..6cda21b41b 100644 --- a/Source/Core/VideoCommon/PixelShaderGen.cpp +++ b/Source/Core/VideoCommon/PixelShaderGen.cpp @@ -361,7 +361,7 @@ void ClearUnusedPixelShaderUidBits(APIType api_type, const ShaderHostConfig& hos uid_data->bounding_box &= host_config.bounding_box & host_config.backend_bbox; } -void WritePixelShaderCommonHeader(ShaderCode& out, APIType api_type, u32 num_texgens, +void WritePixelShaderCommonHeader(ShaderCode& out, APIType api_type, const ShaderHostConfig& host_config, bool bounding_box) { // dot product for integer vectors @@ -546,8 +546,7 @@ ShaderCode GeneratePixelShaderCode(APIType api_type, const ShaderHostConfig& hos uid_data->genMode_numtexgens, uid_data->genMode_numindstages); // Stuff that is shared between ubershaders and pixelgen. - WritePixelShaderCommonHeader(out, api_type, uid_data->genMode_numtexgens, host_config, - uid_data->bounding_box); + WritePixelShaderCommonHeader(out, api_type, host_config, uid_data->bounding_box); if (uid_data->forced_early_z && g_ActiveConfig.backend_info.bSupportsEarlyZ) { diff --git a/Source/Core/VideoCommon/PixelShaderGen.h b/Source/Core/VideoCommon/PixelShaderGen.h index 08724274ee..6691e9c507 100644 --- a/Source/Core/VideoCommon/PixelShaderGen.h +++ b/Source/Core/VideoCommon/PixelShaderGen.h @@ -158,7 +158,7 @@ using PixelShaderUid = ShaderUid; ShaderCode GeneratePixelShaderCode(APIType api_type, const ShaderHostConfig& host_config, const pixel_shader_uid_data* uid_data); -void WritePixelShaderCommonHeader(ShaderCode& out, APIType api_type, u32 num_texgens, +void WritePixelShaderCommonHeader(ShaderCode& out, APIType api_type, const ShaderHostConfig& host_config, bool bounding_box); void ClearUnusedPixelShaderUidBits(APIType api_type, const ShaderHostConfig& host_config, PixelShaderUid* uid); diff --git a/Source/Core/VideoCommon/UberShaderPixel.cpp b/Source/Core/VideoCommon/UberShaderPixel.cpp index 996d3c1d55..f3a1fe2a4b 100644 --- a/Source/Core/VideoCommon/UberShaderPixel.cpp +++ b/Source/Core/VideoCommon/UberShaderPixel.cpp @@ -64,7 +64,7 @@ ShaderCode GenPixelShader(APIType ApiType, const ShaderHostConfig& host_config, out.Write("// Pixel UberShader for {} texgens{}{}\n", numTexgen, early_depth ? ", early-depth" : "", per_pixel_depth ? ", per-pixel depth" : ""); - WritePixelShaderCommonHeader(out, ApiType, numTexgen, host_config, bounding_box); + WritePixelShaderCommonHeader(out, ApiType, host_config, bounding_box); WriteUberShaderCommonHeader(out, ApiType, host_config); if (per_pixel_lighting) WriteLightingFunction(out);