[client] egl: make filters damage aware

This saves a lot of GPU power for partial updates. Running testufo with
lanczos downscaling and FSR upscaling consumed over 90 W, but with this
commit, consumed only 75 W.
This commit is contained in:
Quantum
2021-09-01 22:27:36 -04:00
committed by Geoffrey McRae
parent e9bf225c75
commit 1b58f2592c
10 changed files with 103 additions and 35 deletions

View File

@@ -1,14 +1,15 @@
#version 300 es
precision mediump float;
layout(location = 0) in vec2 uVertex;
layout(location = 1) in vec2 uUV;
layout(location = 0) in vec2 vertex;
out vec2 fragCoord;
uniform vec2 desktopSize;
uniform mat3x2 transform;
void main()
{
gl_Position = vec4(uVertex, 0.0, 1.0);
fragCoord = uUV;
vec2 pos = transform * vec3(vertex, 1.0);
gl_Position = vec4(pos.x, -pos.y, 0.0, 1.0);
fragCoord = vertex / desktopSize;
}