WebGL around the net, 17 March 2010

Some great stuff today:

  • This is an brilliant idea: ANGLE, a [UPDATE Google-sponsored] open source library that implements the OpenGL ES 2.0 specification on top of DirectX. Lots of Windows users, people with laptops in particular, have been disappointed that when they tried to get WebGL running, their graphics cards’ drivers couldn’t support it, and they wound up having to run Minefield with software rendering — which is way too slow for anything but the most trivial WebGL pages. However, much of the time the problem wasn’t the graphics cards themselves — it was the fact that the drivers didn’t support OpenGL 2.1. All of the existing browsers require OpenGL 2.1 in order to run WebGL, but a lot of low-end graphics card manufacturers (I’m looking at you, Intel) don’t support 2.1 in their drivers. They do, however, support DirectX — most PC games are written to that library, and so it would be suicide for a graphics driver to not support it properly. This means that ANGLE can implement an OpenGL ES 2.0 interface on top of DirectX, and then the Minefield and WebKit teams can target ANGLE instead of OpenGL 2.1 — and WebGL will work everywhere. That’s the theory, anyway — and I wish the best of luck to the team developing it! [UPDATE here's the official announcement.]
  • Looks like I wasn’t the only person giving a lightning talk about WebGL at recent Google meetups — here’s one in Japanese. I’m really impressed at how much the author managed to pack into those five minutes!
  • Also for those who read Japanese: a C3DL demo showing how to load a COLLADA file (I think :-) .
  • Kevin Theisen writes to say that last night’s WebKit had antialiasing enabled. Unfortunately it sounds like they had to revert it almost immediately because of a bug, but this will be a big improvement to graphics quality when they get it sorted!
You can leave a response, or trackback from your own site.

10 Responses to “WebGL around the net, 17 March 2010”

  1. Eric says:

    Just a quick note on WebKit’s antialiasing – well not WebKit perse. I’ve noticed that Minefield on Mac doesn’t not support anti aliasing, while Minefield on Linux does. Things look so much nicer on my linux box. Because of the platform dependency within Minefield I almost think it’s a native graphics driver issue. Another difference I’ve noticed is that the Linux nvidia driver is more strict than the Mac one in compiling shader codes. I had a stmt like vec4(some_other_vector, 1); Which didn’t compile on Linux until I changed the second argument to be an explicit floating point constant: 1.0

  2. murphy says:

    How would you enable anitaliasing, if it’s supported? Is there an API?

  3. Eric says:

    5.2.1 Context creation parameters


    var context = canvas.getContext(‘webgl’, { antialias: true});

  4. giles says:

    @Eric — thanks for that! I don’t know if anti-aliasing was on or off by default in the WebKit built Kevin was looking at, I’ll ask him. Re: strict drivers: on my PCs, which have ATI graphics, I’ve found that they are quite happy to accept “1″ as a float, and it’s only when I release something that someone tries it on a Mac (often Murphy :-) and has to remind me that other drivers need 1.0…

    @Paul — thanks for that. I’ve just tried it on my machine, and it didn’t work. So it does sound suspiciously like a driver-dependent feature.

  5. giles says:

    Kevin says that it was on by default, and points out that this is the specified behaviour:

    Default: true. If the value is true and the implementation supports antialiasing the drawing buffer will perform antialiasing using its choice of technique (multisample/supersample) and quality. If the value is false or the implementation does not support antialiasing, no antialiasing is performed.”

    Section 5.2: WebGLContextAttributes

    @Eric — have you had to switch it on manually?

  6. Eric says:

    I’ve tried switching it on manually, but the fact that the impl doesn’t support it overrides that. Bot no in my case, I’m just using the defaults, no arguments passed.

  7. giles says:

    Thanks, Eric — understood. I guess I’m just going to have to stop buying machines with ATI graphics cards ;-)

  8. chriz says:

    @giles, i able run on chromium but fail on minefield after update display driver. I guess it something deal with WDDM.

  9. giles says:

    Thanks, Chriz. Were you able to get stuff working on Minefield before the driver update? Or do you mean that it didn’t work even after you’d updated?

Leave a Reply

Subscribe to RSS Feed Follow Learning WebGL on Twitter