summaryrefslogtreecommitdiff
path: root/Source/Core/VideoBackends/D3D/PixelShaderCache.cpp
diff options
context:
space:
mode:
authorJules Blok <jules.blok@gmail.com>2014-12-03 14:20:46 +0100
committerJules Blok <jules.blok@gmail.com>2014-12-14 13:28:48 +0100
commit6fe7d530ed4e0eec54deb509745a5c17c2c50ae5 (patch)
treefae3b993accae2ee6657b675307790f01c548a9c /Source/Core/VideoBackends/D3D/PixelShaderCache.cpp
parentb2e73400be47fe7765fc6a7a7fb6516e24c78b7d (diff)
PixelShaderCache: Fix MSAA shaders.
Various typos were introduced due to lack of testing.
Diffstat (limited to 'Source/Core/VideoBackends/D3D/PixelShaderCache.cpp')
-rw-r--r--Source/Core/VideoBackends/D3D/PixelShaderCache.cpp18
1 files changed, 9 insertions, 9 deletions
diff --git a/Source/Core/VideoBackends/D3D/PixelShaderCache.cpp b/Source/Core/VideoBackends/D3D/PixelShaderCache.cpp
index 621ae34cea..17290a5ba0 100644
--- a/Source/Core/VideoBackends/D3D/PixelShaderCache.cpp
+++ b/Source/Core/VideoBackends/D3D/PixelShaderCache.cpp
@@ -81,9 +81,9 @@ const char color_copy_program_code_msaa[] = {
"void main(\n"
"out float4 ocol0 : SV_Target,\n"
"in float4 pos : SV_Position,\n"
- "in float3 uv0 : TEXCOORD0,\n"
- "int width, height, samples;\n"
- "Tex0.GetDimensions(width, height, samples);\n"
+ "in float3 uv0 : TEXCOORD0){\n"
+ "int width, height, slices, samples;\n"
+ "Tex0.GetDimensions(width, height, slices, samples);\n"
"ocol0 = 0;\n"
"for(int i = 0; i < samples; ++i)\n"
" ocol0 += Tex0.Load(int3(uv0.x*(width), uv0.y*(height), uv0.z), i);\n"
@@ -113,11 +113,11 @@ const char color_matrix_program_code_msaa[] = {
"out float4 ocol0 : SV_Target,\n"
"in float4 pos : SV_Position,\n"
"in float3 uv0 : TEXCOORD0){\n"
- "int width, height, samples;\n"
- "Tex0.GetDimensions(width, height, samples);\n"
+ "int width, height, slices, samples;\n"
+ "Tex0.GetDimensions(width, height, slices, samples);\n"
"float4 texcol = 0;\n"
"for(int i = 0; i < samples; ++i)\n"
- " texcol += Tex0.Load(int2(uv0.x*(width), uv0.y*(height), uv0.z), i);\n"
+ " texcol += Tex0.Load(int3(uv0.x*(width), uv0.y*(height), uv0.z), i);\n"
"texcol /= samples;\n"
"texcol = round(texcol * cColMatrix[5])*cColMatrix[6];\n"
"ocol0 = float4(dot(texcol,cColMatrix[0]),dot(texcol,cColMatrix[1]),dot(texcol,cColMatrix[2]),dot(texcol,cColMatrix[3])) + cColMatrix[4];\n"
@@ -167,11 +167,11 @@ const char depth_matrix_program_msaa[] = {
"out float4 ocol0 : SV_Target,\n"
" in float4 pos : SV_Position,\n"
" in float3 uv0 : TEXCOORD0){\n"
- " int width, height, samples;\n"
- " Tex0.GetDimensions(width, height, samples);\n"
+ " int width, height, slices, samples;\n"
+ " Tex0.GetDimensions(width, height, slices, samples);\n"
" float4 texcol = 0;\n"
" for(int i = 0; i < samples; ++i)\n"
- " texcol += Tex0.Load(int2(uv0.x*(width), uv0.y*(height), uv0.z), i);\n"
+ " texcol += Tex0.Load(int3(uv0.x*(width), uv0.y*(height), uv0.z), i);\n"
" texcol /= samples;\n"
// 255.99998474121 = 16777215/16777216*256