From f464dfbefa08089433301f011b81c70f100ab18e Mon Sep 17 00:00:00 2001 From: Tom Englund Date: Tue, 1 Jul 2025 11:32:00 +0200 Subject: shader: replace texture2d with texture (#10893) * shader: replace texture2d with texture remove unused v_color and replace deprecated texture2d with texture. * shader: use the more modern essl3 extension GL_OES_EGL_image_external_essl3 provides support for samplerExternalOES in texture function, aquamarine already use it. apply it here too. --- src/render/shaders/glsl/blur1.frag | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src/render/shaders/glsl/blur1.frag') diff --git a/src/render/shaders/glsl/blur1.frag b/src/render/shaders/glsl/blur1.frag index f0f8cc10..796fb42d 100644 --- a/src/render/shaders/glsl/blur1.frag +++ b/src/render/shaders/glsl/blur1.frag @@ -112,11 +112,11 @@ layout(location = 0) out vec4 fragColor; void main() { vec2 uv = v_texcoord * 2.0; - vec4 sum = texture2D(tex, uv) * 4.0; - sum += texture2D(tex, uv - halfpixel.xy * radius); - sum += texture2D(tex, uv + halfpixel.xy * radius); - sum += texture2D(tex, uv + vec2(halfpixel.x, -halfpixel.y) * radius); - sum += texture2D(tex, uv - vec2(halfpixel.x, -halfpixel.y) * radius); + vec4 sum = texture(tex, uv) * 4.0; + sum += texture(tex, uv - halfpixel.xy * radius); + sum += texture(tex, uv + halfpixel.xy * radius); + sum += texture(tex, uv + vec2(halfpixel.x, -halfpixel.y) * radius); + sum += texture(tex, uv - vec2(halfpixel.x, -halfpixel.y) * radius); vec4 color = sum / 8.0; -- cgit v1.2.3