Last night, I checked in some more work from Mark Steele (who’s focusing on the Firefox WebGL implementation), and along with that, enabled WebGL in trunk nightlies. (Finally!)
If you’re not familiar with WebGL, it’s the evolution of work that Mozilla started a few years ago with experiments called Canvas 3D — essentially a way of accessing OpenGL from within the browser, through the HTML5 canvas tag. Earlier this year, we started a standardization effort within the Khronos Group which oversees OpenGL, and have made very rapid progress.
Along with the Firefox implementation, a WebGL implementation landed in WebKit fairly recently. All of these implementations are going to have some interoperability issues for the next little while, as the spec is still in flux and we’re tracking it at different rates, but will hopefully start to stabilize over the next few months.
If you’d like to experiment with WebGL with a trunk nightly build (starting from Friday, September 18th), all you have to do is flip a pref: load about:config, search for “webgl“, and double-click “webgl.enabled_for_all_sites” to change the value from false to true. You’ll currently have the most luck on MacOS X machines or Windows machines with up-to-date OpenGL drivers.
We still have some ways to go, as there are issues in shader security and portability, not to mention figuring out what to do on platforms where OpenGL is not available. (The latter is an interesting problem; we’re trying to ensure that the API can be implementable on top of a non-GL native 3D API, such as Direct3D, so that might be one option.) But progress is being quickly made.
Edit: new post up, with some samples!