WebGL around the net, 7 Jan 2010

A good mix of stuff today!

  • Aaron Babcock has written a version of a classic Flash game to run on the graphics card using WebGL. It’s called Falling Sand; click on one of the palette of materials at the bottom of the page and then drag on the canvas to paint it, add a few bits of different materials, and then sit back and watch… mesmerising!
  • Another hypnotic demo, this one from Emanuele Ruffaldi: a WebGL game of life.
  • Things are hotting up in the race to support WebGL in Google Web Toolkit: there’s another project to get this working, this time from Soenke Sothmann and Steffen Schafer, to add to the two we saw at the end of last year. As Soenke says, “competition stimulates business :-)
  • Finally, a neat demo from murphy; a spinning cube taking its texture from a 2D canvas that shows the time. I particularly like this one because the code is easy to read for anyone who’s been following the lessons here :-) , and it also uses a better setting for the mipmaps (which I should probably retrospectively update the tutorials to use)

That’s all for today! One final thing — tomorrow I’ll be collating the results of the browser tests to see if we can finally get rid of the compatibility cruft in our WebGL code — so if you haven’t done so already, I’d be really grateful if you could check out this page and then post a comment on this post saying what OS and browser you’re using, and what the results were. Thanks!

You can leave a response, or trackback from your own site.

6 Responses to “WebGL around the net, 7 Jan 2010”

  1. aa says:

    Chromium one of the latest build Linux
    Checking WebGL… array types vs Canvas… array types: OK (found WebGLFloatArray)
    Checking context name: OK (got using experimental-webgl)
    Checking parameter getter functions: OK

    Firefox nightly build Linux
    * Checking WebGL… array types vs Canvas… array types: OK (found WebGLFloatArray)
    * Checking context name: OK (got using experimental-webgl)
    * Checking parameter getter functions: OK

  2. murphy says:

    Thanks for the link :) Actually, I think the most interesting thing about using Canvas-2D textures is that you’re able to render text. WebGL will be used to render Web content, and most apps aren’t very useful unless you have some text in them.

  3. giles says:

    That’s a great point. A game might use a C2D layered on top of a WebGL one for a HUD, for example.

    Now, it would be interesting to see what happens if you use one of the new video tags to provide a texture…

  4. giles says:

    Oh, and @aa — thanks!

  5. murphy says:

    Video textures…well, I didn’t check. I assume it’s black, uses the poster graphic, or a still image. An animated texture would be…strange, considering how OpenGL works.

  6. giles says:

    @murphy — well, you’d have to add code to push the current video frame up to the graphics card every frame, of course. Which might make things, um, a bit jerky ;-) But it would look quite impressive…

Leave a Reply

Subscribe to RSS Feed Follow Learning WebGL on Twitter