News for hackers. Stuff that matters.
Re:WebAssembly Raytracer by k__ on Saturday December 16, 2017 @06:53AM (#15939120)
the shader version is the fastest, but looks like modern art on my smartphone.

Like someone scribbled the colors over the circles instead of filling them.

Re:WebAssembly Raytracer by jsheard on Saturday December 16, 2017 @08:15AM (#15939399)
This is probably the culprit: https://github.com/sniklaus/experiment-raytracer/blob/master...

It declares that floats should only be medium precision by default, but those precision specifiers are only followed on mobile platforms.

Desktop WebGL implementations just promote everything to high precision so that kind of bug is invisible until you test on mobile.

Re:WebAssembly Raytracer by k__ on Saturday December 16, 2017 @09:46AM (#15939734)
Made a screenshot: https://imgur.com/a/7J4Da
Re:WebAssembly Raytracer by sniklaus on Saturday December 16, 2017 @03:42PM (#15941962)
Thank you for pointing it out, I fixed it by now. :)
Re:WebAssembly Raytracer by simooooo on Sunday December 17, 2017 @12:00AM (#15944225)
Fixed for me. Nice work
Re:WebAssembly Raytracer by K0nserv on Saturday December 16, 2017 @07:48AM (#15939307)
That's probably an implementation issues that manifests on your hardware called shadow acne/self intersection. It's explained here[0]

0: https://www.scratchapixel.com/lessons/3d-basic-rendering/int...

Re:WebAssembly Raytracer by k__ on Saturday December 16, 2017 @09:46AM (#15939735)
Made a screenshot: https://imgur.com/a/7J4Da