From fd4a1137a23836df63b94d27161587d2cfcd1d01 Mon Sep 17 00:00:00 2001 From: Michael Oppitz Date: Wed, 27 Sep 2023 12:22:53 +0200 Subject: [PATCH] fix: depth issue on Android devices --- src/ao/shader/ao_compose.frag | 2 +- src/hbao/shader/hbao.frag | 2 +- src/poissionDenoise/shader/poissionDenoise.frag | 2 +- src/ssao/shader/ssao.frag | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/ao/shader/ao_compose.frag b/src/ao/shader/ao_compose.frag index 28f4b04c..b5d0f343 100644 --- a/src/ao/shader/ao_compose.frag +++ b/src/ao/shader/ao_compose.frag @@ -1,5 +1,5 @@ uniform sampler2D inputTexture; -uniform sampler2D depthTexture; +uniform highp sampler2D depthTexture; uniform float power; uniform vec3 color; diff --git a/src/hbao/shader/hbao.frag b/src/hbao/shader/hbao.frag index 35a5f068..0a8f7cf8 100644 --- a/src/hbao/shader/hbao.frag +++ b/src/hbao/shader/hbao.frag @@ -1,6 +1,6 @@ varying vec2 vUv; -uniform sampler2D depthTexture; +uniform highp sampler2D depthTexture; uniform mat4 projectionViewMatrix; uniform int frame; diff --git a/src/poissionDenoise/shader/poissionDenoise.frag b/src/poissionDenoise/shader/poissionDenoise.frag index 8d5c6508..954cf377 100644 --- a/src/poissionDenoise/shader/poissionDenoise.frag +++ b/src/poissionDenoise/shader/poissionDenoise.frag @@ -1,7 +1,7 @@ varying vec2 vUv; uniform sampler2D inputTexture; -uniform sampler2D depthTexture; +uniform highp sampler2D depthTexture; uniform sampler2D normalTexture; uniform mat4 projectionMatrixInverse; uniform mat4 cameraMatrixWorld; diff --git a/src/ssao/shader/ssao.frag b/src/ssao/shader/ssao.frag index 5103cf09..271f458c 100644 --- a/src/ssao/shader/ssao.frag +++ b/src/ssao/shader/ssao.frag @@ -1,6 +1,6 @@ varying vec2 vUv; -uniform sampler2D depthTexture; +uniform highp sampler2D depthTexture; uniform sampler2D normalTexture; uniform mat4 projectionViewMatrix; uniform mat4 cameraMatrixWorld;