Do all the things like ++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatarSign Up
Get a devDuck
Rubber duck debugging has never been so cute! Get your favorite coding language devDuckBuy Now
Search - "raytracing"
My dream project is to work on a Hollywood grade raytracing engine (Pixar Renderman, Disney Hyperion,...) I have done some hobby grade ones like to produce the image here6
Well i this is the end.
Somebody implemented full raytracing in fucking excel.
Full movement and everything.
Im fucking done.
I cant even imagine how long did it take but oh well.
There is no turning back.
He did it already.
Link to the video in comments.
//This is not my video and i have no worked on this. Full credit goes to the guy.16
While writing a raytracing engine for my university project (a fairly long and complex program in C++), there was a subtle bug that, under very specific conditions, the ray energy calculation would return 0 or NaN, and the corresponding pixel would be slightly dimmer than it should be.
Now you might think that this is a trifling problem, but when it happened to random pixels across the screen at random times it would manifest as noise, and as you might know, people who render stuff Absolutely. Hate. Noise. It wouldn't do. Not acceptable.
So I worked at that thing for three whole days and finally located the bug, a tiny gotcha-type thing in a numerical routine in one corner of the module that handled multiple importance sampling (basically, mixing different sampling strategies).
Frustrating, exhausting, and easily the most gruelling bug hunt I've ever done. Utterly worth it when I fixed it. And what's even better, I found and squashed two other bugs I hadn't even noticed, lol
So my homegrown raytracing engine somehow managed to render this.
(It's supposed to be a material approximating oldish gold: a texture, a diffuse material model and a specular material model)
(Note the reddish bright interior areas. I think energy isn't being conserved in the specular BSDF. Bug. Gah.)2
can we just get rid of floating points? or at least make it quite clear that they are almost certainly not to be used.
yes, they have some interesting properties that make them good for special tasks like raytracing and very special forms of math. but for most stuff, storing as much smaller increments and dividing at the end (ie. don't store money as 23.45. store as 2,345. the math is the same. implement display logic when showing it.) works for almost all tasks.
floating point math is broken! and most people who really, truely actually need it can explain why, which bits do what, and how to avoid rounding errors or why they are not significant to their task.
or better yet can we design a standard complex number system to handle repeating divisions and then it won't be an issue?
footnote: (I may not be perfectly accurate here. please correct if you know more)
much like 1/3 (0.3333333...) in base 10 repeats forever, that happens with 0.1 in base 2 because of how floats store things.
this, among other reasons, is why 0.1+0.2 returns 0.300000046
I'm excited about flutter, looks like it will make cross platform mobile dev more fun.
Also dx12 rtx real time raytracing. It would be cool to work on it at work. We do animations for short movies at work and render times are huge now.
I'm kinda suspicious for both though. Couldn't check it out yet.1