Skip to content

Commit

Permalink
cornell: Temporarily work around issue #337
Browse files Browse the repository at this point in the history
  • Loading branch information
ben-clayton committed Dec 11, 2023
1 parent 21b1a14 commit 667a744
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/sample/cornell/common.wgsl
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ fn rand() -> f32 {
7919 * 631 * 5 * 3);

rnd = (rnd * C) ^ (rnd.yzx >> vec3(4u));
return f32(rnd.x ^ rnd.y) / f32(0xffffffff);
return f32(rnd.x ^ rnd.y) / 4294967295.0; // 4294967295.0 is f32(0xffffffff). See #337
}

// Returns a random point within a unit sphere centered at (0,0,0).
Expand Down

0 comments on commit 667a744

Please sign in to comment.