DarioSamo/sm64rt-legacy-renderer

AMD hardware glitches around borders of geometry when several solid pieces of geometry are found by the same ray in the anyhit shader

Closed this issue · 5 comments

The debug views show the primary ray is clearly at fault here, and it's a possibility the sorting code itself is broken as well.

image
image

Probably worth testing with a lower max hit count just in case it's running into some limitation due to the buffer's size.

Anton has found a workaround for this issue, although it seems more research is still pending.

https://twitter.com/antonschrein/status/1421492814161063936

Placing samplers on the heap solves(instead of static samplers in the signature). looks like a compiler bug maybe - not placing static sampler load properly or something. I can send code if needed but that's a small change, just add sampler heap parameter

https://twitter.com/antonschrein/status/1421840748194959363

Workaround seems to do the trick in dynamic_samplers, although no measurements if it actually impacts performance yet or a good explanation as to why the glitch happens in the first place.

Fixed in dev