From 7d41bb838d04cd543e11a91bee815199e68bde42 Mon Sep 17 00:00:00 2001 From: ice_iix Date: Mon, 19 Nov 2018 17:44:06 -0800 Subject: [PATCH] Revert "Change multisampling count to 0, improved fix/workaround for AMD GPUs (#26)" NUM_SAMPLES=0 or 1 breaks AMD Radeon R9 M295X on Windows 11, but 2 works. This reverts commit 748911a91b09adc666638c2fcba122e610f2090b. --- src/render/mod.rs | 2 +- src/render/shaders/trans_frag.glsl | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/src/render/mod.rs b/src/render/mod.rs index e27bb42..bcc538e 100644 --- a/src/render/mod.rs +++ b/src/render/mod.rs @@ -43,7 +43,7 @@ use std::sync::mpsc; const ATLAS_SIZE: usize = 1024; // TEMP -const NUM_SAMPLES: i32 = 0; +const NUM_SAMPLES: i32 = 2; pub struct Camera { pub pos: cgmath::Point3, diff --git a/src/render/shaders/trans_frag.glsl b/src/render/shaders/trans_frag.glsl index dcf8118..123e4c3 100644 --- a/src/render/shaders/trans_frag.glsl +++ b/src/render/shaders/trans_frag.glsl @@ -15,7 +15,6 @@ void main() { for (int i = 1; i < samples; i++) { col += texelFetch(tcolor, C, i); } - if (samples != 0) col /= float(samples); float r = accum.a;