From 4ea40c7611cc57730f03a3a61537a741c41af6b3 Mon Sep 17 00:00:00 2001 From: "Blue (Lukas Rieger)" Date: Thu, 2 Jul 2020 19:52:28 +0200 Subject: [PATCH] Define EPSILON, since it seems not to be defined by default on all systems. Fixes #48 --- .../src/main/webroot/js/libs/shaders/HiresVertexShader.js | 1 + .../src/main/webroot/js/libs/shaders/LowresVertexShader.js | 1 + 2 files changed, 2 insertions(+) diff --git a/BlueMapCore/src/main/webroot/js/libs/shaders/HiresVertexShader.js b/BlueMapCore/src/main/webroot/js/libs/shaders/HiresVertexShader.js index 0feab341..e0f1cfe1 100644 --- a/BlueMapCore/src/main/webroot/js/libs/shaders/HiresVertexShader.js +++ b/BlueMapCore/src/main/webroot/js/libs/shaders/HiresVertexShader.js @@ -25,6 +25,7 @@ import { ShaderChunk } from 'three'; const HIRES_VERTEX_SHADER = ` +#define EPSILON 1e-6 ${ShaderChunk.logdepthbuf_pars_vertex} attribute float ao; diff --git a/BlueMapCore/src/main/webroot/js/libs/shaders/LowresVertexShader.js b/BlueMapCore/src/main/webroot/js/libs/shaders/LowresVertexShader.js index ae9a4485..8cd668f5 100644 --- a/BlueMapCore/src/main/webroot/js/libs/shaders/LowresVertexShader.js +++ b/BlueMapCore/src/main/webroot/js/libs/shaders/LowresVertexShader.js @@ -25,6 +25,7 @@ import { ShaderChunk } from 'three'; const LOWRES_VERTEX_SHADER = ` +#define EPSILON 1e-6 ${ShaderChunk.logdepthbuf_pars_vertex} varying vec3 vPosition;