From 5c8d7836de0d635688a726b87f1f192f5eea7d75 Mon Sep 17 00:00:00 2001 From: Lars Michelsen Date: Sat, 16 Mar 2019 00:13:29 +0100 Subject: [PATCH] Fix overflow of 2 sides in emulator mode --- emulator.glsl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/emulator.glsl b/emulator.glsl index 4aae397..38a9b54 100644 --- a/emulator.glsl +++ b/emulator.glsl @@ -119,7 +119,7 @@ void mainImage(out vec4 fragColor, in vec2 fragCoord) { float pixSize = .35; vec4 sideCoord = cube_map_to_side(p); if (length(mod(sideCoord.xy * grid, 1) - .5) < pixSize) { - mainCube(fragColor, round(p * grid - .5) / grid); + mainCube(fragColor, p); } else { fragColor = vec4(0); }