[client] egl: provide the texture scale to the desktop shader

If the texture has a post-processing filter that has scaled the texture,
the desktop fragment shader needs to know this if it's doing linear
scaling.
This commit is contained in:
Geoffrey McRae
2021-08-09 18:22:28 +10:00
parent f7f8060447
commit 6882e5c59f
4 changed files with 23 additions and 6 deletions

View File

@@ -339,6 +339,7 @@ enum EGL_TexStatus egl_textureAddShader(EGL_Texture * this, EGL_Shader * shader,
glGenTextures(1, &step->tex);
step->shader = shader;
step->scale = outputScale;
this->scale = outputScale;
if (this->formatValid)
if (!setupRenderStep(this, step))
@@ -351,3 +352,8 @@ enum EGL_TexStatus egl_textureAddShader(EGL_Texture * this, EGL_Shader * shader,
ll_push(this->render, step);
return EGL_TEX_STATUS_OK;
}
float egl_textureGetScale(EGL_Texture * this)
{
return this->scale;
}