Skip to content

Commit 683b9e4

Browse files
fix the nasty noise bug
1 parent bb4f35d commit 683b9e4

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

examples_tests/22.RaytracedAO/closestHit.comp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ void main()
4444
const nbl_glsl_ext_RadeonRays_ray ray = sourceRays[gl_GlobalInvocationID.x];
4545

4646
const uint batchInstanceGUID = intersection.shapeid;
47-
const uint invalidID = 0x80000000u;
47+
const uint invalidID = 0xffffffffu;
4848
hit = batchInstanceGUID!=invalidID;
4949

5050
const uvec2 outPixelLocation = unpackOutPixelLocation(ray.time);
@@ -76,7 +76,7 @@ void main()
7676
const nbl_glsl_MC_oriented_material_t material = nbl_glsl_MC_material_data_t_getOriented(batchInstanceData.material,frontfacing);
7777
emissive = nbl_glsl_MC_oriented_material_t_getEmissive(material);
7878

79-
const bool _continue = vertex_depth!=MAX_PATH_DEPTH && ray.maxT==FLT_MAX; // last vertex or was a NEE path
79+
const bool _continue = vertex_depth!=MAX_PATH_DEPTH && ray.maxT==nbl_glsl_FLT_MAX; // last vertex or was a NEE path
8080
if (_continue)
8181
{
8282
// if we ever support spatially varying emissive, we'll need to hoist barycentric computation and UV fetching to the position fetching

0 commit comments

Comments
 (0)