From bb56f096c8fbbc9de622bcc686b6d4e2b3ec7e3b Mon Sep 17 00:00:00 2001 From: TheRedShip Date: Sat, 11 Jan 2025 14:22:46 +0100 Subject: [PATCH] + | Pixelisation problem fixed --- .vscode/settings.json | 3 ++- scenes/test.rt | 2 +- shaders/compute.glsl | 5 +---- 3 files changed, 4 insertions(+), 6 deletions(-) diff --git a/.vscode/settings.json b/.vscode/settings.json index 8ef9c99..8a1f376 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -80,5 +80,6 @@ "xlocmon": "cpp", "xloctime": "cpp", "xtree": "cpp" - } + }, + "cmake.ignoreCMakeListsMissing": true } \ No newline at end of file diff --git a/scenes/test.rt b/scenes/test.rt index a185df2..866ca35 100644 --- a/scenes/test.rt +++ b/scenes/test.rt @@ -1,4 +1,4 @@ -CAM 1.43879 3.42554 1.94198 -44.6001 -139.599 0.2 4 90 5 +CAM 1.43879 3.42554 1.94198 -44.6001 -139.599 0 4 90 5 MAT 200 200 200 0.0 0.0 0.0 //white diff --git a/shaders/compute.glsl b/shaders/compute.glsl index ff60468..70ce97d 100644 --- a/shaders/compute.glsl +++ b/shaders/compute.glsl @@ -151,7 +151,7 @@ vec3 pathtrace(Ray ray, inout uint rng_state) hitInfo hit = traceRay(ray); if (hit.obj_index == -1) { - // light += GetEnvironmentLight(ray); + light += GetEnvironmentLight(ray); // light += vec3(135 / 255.0f, 206 / 255.0f, 235 / 255.0f); //ambient color break; } @@ -209,10 +209,7 @@ void main() return; if (u_pixelisation != 1 && (uint(pixel_coords.x) % u_pixelisation != 0 || uint(pixel_coords.y) % u_pixelisation != 0)) - { - imageStore(accumulation_image, pixel_coords, vec4(0.0)); return; - } uint rng_state = uint(u_resolution.x) * uint(pixel_coords.y) + uint(pixel_coords.x); rng_state = rng_state + u_frameCount * 719393;