From b968e46ee26d46abdb1a465424830a367842cf1a Mon Sep 17 00:00:00 2001 From: Richard Davey Date: Tue, 28 Sep 2021 15:56:54 +0100 Subject: [PATCH] The Multi Pipeline now uses `highp float` precision by default, instead of `mediump`. This fixes issues with strange blue 'spots' appearing under WebGL on some Android devices. Fix #5751 #5659 #5655 --- src/renderer/webgl/shaders/Multi-frag.js | 2 +- src/renderer/webgl/shaders/Multi-vert.js | 2 +- src/renderer/webgl/shaders/src/Multi.frag | 2 +- src/renderer/webgl/shaders/src/Multi.vert | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/renderer/webgl/shaders/Multi-frag.js b/src/renderer/webgl/shaders/Multi-frag.js index 2a3d63ebe..ddfa620d1 100644 --- a/src/renderer/webgl/shaders/Multi-frag.js +++ b/src/renderer/webgl/shaders/Multi-frag.js @@ -1,7 +1,7 @@ module.exports = [ '#define SHADER_NAME PHASER_MULTI_FS', '', - 'precision mediump float;', + 'precision highp float;', '', 'uniform sampler2D uMainSampler[%count%];', '', diff --git a/src/renderer/webgl/shaders/Multi-vert.js b/src/renderer/webgl/shaders/Multi-vert.js index fda290ea2..da7b87436 100644 --- a/src/renderer/webgl/shaders/Multi-vert.js +++ b/src/renderer/webgl/shaders/Multi-vert.js @@ -1,7 +1,7 @@ module.exports = [ '#define SHADER_NAME PHASER_MULTI_VS', '', - 'precision mediump float;', + 'precision highp float;', '', 'uniform mat4 uProjectionMatrix;', '', diff --git a/src/renderer/webgl/shaders/src/Multi.frag b/src/renderer/webgl/shaders/src/Multi.frag index 870886e0a..771b65ced 100644 --- a/src/renderer/webgl/shaders/src/Multi.frag +++ b/src/renderer/webgl/shaders/src/Multi.frag @@ -1,6 +1,6 @@ #define SHADER_NAME PHASER_MULTI_FS -precision mediump float; +precision highp float; uniform sampler2D uMainSampler[%count%]; diff --git a/src/renderer/webgl/shaders/src/Multi.vert b/src/renderer/webgl/shaders/src/Multi.vert index ca63f367c..2a869ac5a 100644 --- a/src/renderer/webgl/shaders/src/Multi.vert +++ b/src/renderer/webgl/shaders/src/Multi.vert @@ -1,6 +1,6 @@ #define SHADER_NAME PHASER_MULTI_VS -precision mediump float; +precision highp float; uniform mat4 uProjectionMatrix;