Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
ggambetta
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
107 ms
·
1171.
▲
by
ggambetta
13y ago
Right, just diffuse + specular with different coefficients. Nothing fancy about the materials.
1172.
▲
by
ggambetta
13y ago
For minification, as someone else said. I originally wrote this for a JS1K competition some years ago, so it's not geared towards readability, but towards small code size. I had a really, really ugly trick that saved me a couple of byt
1173.
▲
Recursive raytracer in 35 lines of JavaScript
(jsfiddle.net)
281 points
by
ggambetta
13y ago
|
101 comments
1174.
▲
by
ggambetta
13y ago
Self-taught, ran a game development company, now a happy Googler. 1) There was a ZX Spectrum at home, which booted to a BASIC interpreter. My dad taught me the basics (no pun intended) and I picked up the rest from experimentation and copyi
1175.
▲
by
ggambetta
13y ago
I love this kind of thing. I've made a similar one (minus texturing) in Javascript, drawing to a Canvas; my current version is 975 bytes. Output, full source and live demo here: http://gabrielgambetta.com/tiny_raytracer