This afternoon Will (the friend I mentioned in this previous post) showed up again on Google Talk.
He set me a new challenge: “How about translating your 3d engine/mandelbulb code into pure Javascript?”

First Mandelbulb render, full of programming bugs

This seemed impossible, but I quickly realized the code I had was very easy to convert. It is my first piece of Javascript larger than 10 lines I think, but it is working!

If you have a bit of time:
>>> mandelbulb.js

Any Javascript developers who would like to take the code and improve on it (trust me, there is more then enough room for improvement) go ahead! I’m releasing it under creative commons, do with it what you like, just be sure to mention me!

The code can be found here: https://github.com/royvanrijn/mandelbulb.js

I’ve already included one improvement by Will himself, scanlines to smooth up the rendering (good for inpatient people!).

Tagged with:
 

One Response to Introducing: mandelbulb.js

  1. tim says:

    This is great! I am looking to port this into javascript code inside of Max Msp. If interested i’ll let you know how that goes.

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title="" rel=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>