mirror of https://github.com/PCSX2/pcsx2.git
GS:HW: Remove comment on rgba to 8i only-blue optimization
Doesn't seem to improve anything anymore (GPUs do this with csel now anyways, it's like 5 instructions with no divergence)
This commit is contained in:
parent
c6add663f8
commit
1ad6605dfb
|
@ -262,14 +262,6 @@ PS_OUTPUT ps_convert_rgba_8i(PS_INPUT input)
|
|||
{
|
||||
PS_OUTPUT output;
|
||||
|
||||
// Potential speed optimization. There is a high probability that
|
||||
// game only want to extract a single channel (blue). It will allow
|
||||
// to remove most of the conditional operation and yield a +2/3 fps
|
||||
// boost on MGS3
|
||||
//
|
||||
// Hypothesis wrong in Prince of Persia ... Seriously WTF !
|
||||
//#define ONLY_BLUE;
|
||||
|
||||
// Convert a RGBA texture into a 8 bits packed texture
|
||||
// Input column: 8x2 RGBA pixels
|
||||
// 0: 8 RGBA
|
||||
|
@ -298,13 +290,9 @@ PS_OUTPUT ps_convert_rgba_8i(PS_INPUT input)
|
|||
coord *= PS_SCALE_FACTOR;
|
||||
|
||||
float4 pixel = Texture.Load(int3(int2(coord), 0));
|
||||
#ifdef ONLY_BLUE
|
||||
output.c = (float4)(pixel.b); // Divide by something here?
|
||||
#else
|
||||
float2 sel0 = (pos.y & 2u) == 0u ? pixel.rb : pixel.ga;
|
||||
float sel1 = (pos.x & 8u) == 0u ? sel0.x : sel0.y;
|
||||
output.c = (float4)(sel1); // Divide by something here?
|
||||
#endif
|
||||
return output;
|
||||
}
|
||||
|
||||
|
|
|
@ -208,15 +208,6 @@ void ps_convert_rgb5a1_float16_biln()
|
|||
#ifdef ps_convert_rgba_8i
|
||||
void ps_convert_rgba_8i()
|
||||
{
|
||||
|
||||
// Potential speed optimization. There is a high probability that
|
||||
// game only want to extract a single channel (blue). It will allow
|
||||
// to remove most of the conditional operation and yield a +2/3 fps
|
||||
// boost on MGS3
|
||||
//
|
||||
// Hypothesis wrong in Prince of Persia ... Seriously WTF !
|
||||
//#define ONLY_BLUE;
|
||||
|
||||
// Convert a RGBA texture into a 8 bits packed texture
|
||||
// Input column: 8x2 RGBA pixels
|
||||
// 0: 8 RGBA
|
||||
|
@ -245,13 +236,9 @@ void ps_convert_rgba_8i()
|
|||
coord *= PS_SCALE_FACTOR;
|
||||
|
||||
vec4 pixel = texelFetch(TextureSampler, ivec2(coord), 0);
|
||||
#ifdef ONLY_BLUE
|
||||
SV_Target0 = vec4(pixel.b);
|
||||
#else
|
||||
vec2 sel0 = (pos.y & 2u) == 0u ? pixel.rb : pixel.ga;
|
||||
float sel1 = (pos.x & 8u) == 0u ? sel0.x : sel0.y;
|
||||
SV_Target0 = vec4(sel1);
|
||||
#endif
|
||||
}
|
||||
#endif
|
||||
|
||||
|
|
|
@ -243,14 +243,6 @@ void ps_convert_rgb5a1_float16_biln()
|
|||
#ifdef ps_convert_rgba_8i
|
||||
void ps_convert_rgba_8i()
|
||||
{
|
||||
// Potential speed optimization. There is a high probability that
|
||||
// game only want to extract a single channel (blue). It will allow
|
||||
// to remove most of the conditional operation and yield a +2/3 fps
|
||||
// boost on MGS3
|
||||
//
|
||||
// Hypothesis wrong in Prince of Persia ... Seriously WTF !
|
||||
//#define ONLY_BLUE;
|
||||
|
||||
// Convert a RGBA texture into a 8 bits packed texture
|
||||
// Input column: 8x2 RGBA pixels
|
||||
// 0: 8 RGBA
|
||||
|
@ -279,13 +271,9 @@ void ps_convert_rgba_8i()
|
|||
coord *= PS_SCALE_FACTOR;
|
||||
|
||||
vec4 pixel = texelFetch(samp0, ivec2(coord), 0);
|
||||
#ifdef ONLY_BLUE
|
||||
o_col0 = vec4(pixel.b); // Divide by something here?
|
||||
#else
|
||||
vec2 sel0 = (pos.y & 2u) == 0u ? pixel.rb : pixel.ga;
|
||||
float sel1 = (pos.x & 8u) == 0u ? sel0.x : sel0.y;
|
||||
o_col0 = vec4(sel1); // Divide by something here?
|
||||
#endif
|
||||
}
|
||||
#endif
|
||||
|
||||
|
|
Loading…
Reference in New Issue