JSFarm is a P2P distributed raytracer that runs in your browser.

The project is inspired by PoVRay; scenes are written in a Lisp dialect and rendering is distributed over computers connected to the network.

If you want to jump right in, the best place to start is this tutorial.

Also, there's a bunch of examples below.

Otherwise, have some text.

So what's up with this project?

It started with the desire to write a raytracer like the ones I used as a kid. Something not focused on photorealistic graphics, or movie production, or hyperrealistic skin subsurface scattering or whatever, but geometric shapes and scripted scenes. If you've ever used PoVRay, you know what I mean. But modern! Without a need to install yet another program, without having to mess with installers and permissions, multithreaded from the start instead of bolted on, able to scale to hundreds of boxes, running at native performance of course. So why not run it in the browser, I thought? Okay, so there's actually lots and lots of reasons why that's a bad idea.

So all the pieces were actually in place! I decided on Lisp as a scene description language, because it's incredibly easy to parse, and went to work. A few months later, the project was basically done and I was looking forward to announcing it everywhere! All I had to do was write some proper documentation.

So for the next four months, nothing happened. Turns out, writing documentation is really unrewarding? Who could have predicted this. So by the time I'd nearly finished another language (TBA!), I decided that if I was gonna wait for documentation to be ready, I'd never release the damn thing.

So here it is! Presenting JSFarm: P2P distributed raytracing for your browser. The base language is completely undocumented, but things should mostly work like they do in Lisp. There's a tutorial that I'd written up, which introduces the basics of the scene language, a FAQ, and an introduction to the user interface on Github. Click "Connect" at the top of the main page to connect to the network and start helping others compute pictures, click "save" to save your scene to Gist. (Note that there's a rate limit of about one save a minute.) To share scenes with others, just copy the address. Poke me on Freenode in #jsfarm if you have questions. And above all: have fun rendering!

Some example scenes

Cornell box
Glowsticks
Tunnel
Pavillon
Checkers Lamps
Lenses (slow!)

[light]  [dark]