mirror of
https://github.com/hrydgard/ppsspp.git
synced 2025-04-02 11:01:50 -04:00
GPU: Avoid large constant in depal shader.
This commit is contained in:
parent
0f4f9997fd
commit
761fdd353f
1 changed files with 2 additions and 1 deletions
|
@ -61,7 +61,8 @@ void GenerateDepalShader300(ShaderWriter &writer, const DepalConfig &config) {
|
|||
if (config.depthUpperBits == 0x2) {
|
||||
writer.C(R"(
|
||||
int x = int((texcoord.x / scaleFactor) * texSize.x);
|
||||
int temp = (x & 0xFFFFFE0F) | ((x >> 1) & 0xF0) | ((x << 4) & 0x100);
|
||||
int xclear = x & 0x01F0;
|
||||
int temp = (x - xclear) | ((x >> 1) & 0xF0) | ((x << 4) & 0x100);
|
||||
texcoord.x = (float(temp) / texSize.x) * scaleFactor;
|
||||
)");
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue