Skip to content
This repository was archived by the owner on Nov 22, 2022. It is now read-only.

Commit 614518f

Browse files
author
Lucas Crane
authored
fix crash on windows (#69)
1 parent 35b4fa8 commit 614518f

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/renderer/glsl/rayTrace.frag

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -90,10 +90,11 @@ source: (defines) => `
9090
// for (int i = 1; i < defines.bounces + 1, i += 1)
9191
// equivelant to
9292
${unrollLoop('i', 2, defines.BOUNCES + 1, 1, `
93-
if (!path.abort) {
94-
intersectScene(path.ray, si);
95-
bounce(path, i, si);
93+
if (path.abort) {
94+
return vec4(path.li, path.alpha);
9695
}
96+
intersectScene(path.ray, si);
97+
bounce(path, i, si);
9798
`)}
9899

99100
return vec4(path.li, path.alpha);

0 commit comments

Comments
 (0)