Unleashing GPU acceleration on the web
Tuesday, September 14, 2010
Since our previous post, we've made good progress on 2D graphics performance: 2D canvas acceleration is now available in trunk and the canary build by using the --enable-accelerated-2d-canvas command-line switch (coming to the developer channel shortly). We’ve also been hard at work improving our 3D graphics stack. Today, we’re excited to release a set of WebGL demos to help highlight what you can do with the API.
Chromium’s 2D canvas acceleration uses the same GPU process infrastructure as the compositor, which is designed to maintain the same stability and security Chromium has always had. In addition, this system picks the best graphics API to use on each OS that Chromium supports: Windows XP/Vista/7, Mac OS and Linux. We haven’t finished implementing accelerated 2D canvas support – there’s no Mac support and some functions are not accelerated yet – but Chromium already achieves some impressive gains on the recent IE9 Platform Preview Test Drive 2D canvas demos:
These early numbers show up to 60x speed improvement over the current version of Google Chrome. With Google Chrome’s fast release cycles, we expect to be able to get these enhancements to users quickly and add new performance improvements over time.
We’re excited to give developers fast 2D graphics, but we think truly hardware accelerating graphics on the web means giving developers access to a programmable 3D graphics pipeline with WebGL. Even with accelerated 2D canvas and SVG, it’s still not possible to achieve many graphics effects with these APIs. (To read more about the progression from dynamic 2D to CSS Transforms and WebGL, check out our recent blog post). With WebGL and 3D CSS, developers can create modern games, impressive photo galleries, 3D data visualizations, virtual environments, and whatever else they can dream up.
To give you a taste for what WebGL can do, we’ve worked with a number of talented artists and developers to create the first round of a series of demos, ranging from a realistic aquarium to a 3D wall of photos. We hope these demos help demonstrate even more immersive experiences made possible with these APIs. So check out our demo gallery with an up-to-date canary build or Chromium build and have some fun with using your GPU in the browser! For a quick peek at some of these demos, you can watch our playlist of preview videos:

24 comments:
richtaur said...
Phew, that's hot! Chrome is already the fastest platform for our HTML5 games. Looks like that'll only continue!
September 14, 2010 1:57 PM
Steve Waite said...
Who needs flash?
September 14, 2010 4:30 PM
Fabio Turati said...
Do you plan to make use of GPU acceleration optional? I don't care whether opt-in or opt-out, but I'd really like to be able to turn it off... The reason is simple: my laptop has one of the infamous Geforce 8400M GS cards, and there's a high chance it's one of the faulty ones, those that can get damaged with high temperatures. I'm trying to avoid using the GPU as much as possible. I know it's nVidia's fault and not yours... But I'd really like to be able to turn off GPU acceleration in order to preserve it.
If you make it possible, thanks in advance!
September 14, 2010 4:31 PM
Henry Bridge said...
@Fabio Turati
Thanks for the feedback. We'll definitely turn GPU acceleration on/off based on what hardware you're running, and you can always use command-line switches (like --disable-webgl and --disable-accelerated-compositing), but we haven't decided whether there will be a user-facing option for GPU acceleration yet.
September 14, 2010 4:37 PM
Mike said...
All very nifty.
Something I've been wondering since this GPU-accelerated browsing hoo-ha kicked off: have there been any discussions about getting GPU vendors to provide OpenVG support for desktop OSes? As with so many of the Khronos standards it seems to have gone nowhere outside of mobile, but it looks much better suited to accelerating HTML, SVG and possibly Canvas rendering than full OpenGL, especially with regard to text.
September 14, 2010 5:41 PM
Andrex said...
Amazing! Thanks Chrome team. This pushed my to finally install Canary.
I can't wait until WebGL is hardware accelerated (I think you guys will be the first ones to do it, as the IE9 team has been mum on it due to DirectX.)
September 14, 2010 5:42 PM
Mark said...
If you're looking for a wider market appeal I'd suggest going for UI options instead of command line flags only for GPU acceleration, at least from a Windows users perspective.
I'm a pretty savvy computer user and as I get older I become less and less inclined to sift through documents to see what flags are available and much prefer having the option listed in the Options menu.
20+ years ago I loved poking around in the OS, tweaking things via command line flags etc etc (Sometimes I miss 4DOS yo!). Now that interfaces have advanced I often feel that option menus should move with the times.
September 14, 2010 5:46 PM
pseudocube said...
"Your browser doesn't appear to support WebGL."
Running Canary 7.0.524.0 on Windows.
September 14, 2010 8:13 PM
Cwize1 said...
Fish bowls have been around for ages. They are quite boring. Now if you made a web version of Blender then I would be impressed.
September 15, 2010 12:02 AM
Tuan Kuranes said...
Congrats for the big move, chrome definitely the faster canvas browser now. (was opera here before)
* Is video decoding GPU accelerated or planned to be ? (first missing bits to beat flash)
* Any way filters/"image shaders" or like flash pixel bender like can make it into canvas in a way or another ? That would dramatically improve speed. Either using shader language, a canvas DSL+llvm, or just sort of function convention that would help you detect the cases. (second missing bits to beat flash)
* A way to do in GPU "texture to texture" copy in canvas (way faster than downloading from GPU, do some copy and upload to GPU) ?
Samples that would gain from it:
video + copy http://people.mozilla.com/~prouget/demos/DynamicContentInjection/play.xhtml
filters :
http://10k.aneventapart.com/Uploads/219/
http://mugtug.com/darkroom/
@pseudocube You need command line arguments :
chrome.exe --enable-webgl --enable-accelerated-compositing --enable-accelerated-2d-canvas
(but win7 has a command line limit size on shortcuts .lnk ... )
September 15, 2010 12:29 AM
Renault said...
Bravo! This look amazing. I have 2 questions though:
1. How portable is your hardware accelerated code? Could it be ported to an embedded device, for example?
2. I'm unclear on were the code will live. Will it be an extension to WebKit or a separated graphic pipeline?
Thanks
Renault
September 15, 2010 12:42 AM
Martin said...
How about moving the switches to about:labs section? Like Tuan Kuranes said, command line switches are not very comfortable to use on Windows, especially as they are not applied when Chrome is opened by an external Application (Outlook or the Explorer by clicking an HTML file for example).
September 15, 2010 2:47 AM
broc said...
I am looking for documentation on whether my integrated DirectX9 GMA 3100 is supported.
September 15, 2010 7:29 AM
Guspaz said...
Some sort of about:switches that had the *full* list of command-line switches available, and the ability to enable/disable them from inside the browser, would be greatly appreciated. As has been said before, switches are annoying on Windows, and it'd be nice to be able to just say "I always want --enable-foo in effect".
September 15, 2010 9:51 AM
Roman Rytov said...
are there the technical spec for the platform to be capable rendering it all? also the asked question on the mobile version of the chrome to support is intriguing to me.
September 16, 2010 11:13 AM
Pau said...
Now it's time for a web game development contest!
It would be great if Google could organize it :)
September 16, 2010 11:34 PM
jia said...
great all things tahnks for all information..
www.webconnecttechnologies.com
September 17, 2010 11:16 PM
Jonidimo said...
I can't use this, when I add --enable-accelerated-2d-canvas command-line there are a lot of webs that don't work. Even the download web of chrome goes to 'aw, snap!'. I have windows seven 64, cpu: phenom II, vga: 5770.
September 18, 2010 3:54 PM
Andreea Cristescu said...
Now you can get rid of Flash, since it seems games will be more advanced in HTML5 than in Flash anyway. Why do you guys support an technology like that?
September 18, 2010 11:30 PM
Edchick said...
Slightly off topic:
I have a computer with Pentium M and 1GB Memory. And both Opera and Firefox handles 30 Tabs on it fairly well. But Chrome simply cant not handle it due to its process per tab architecture. Is it possible to bring back Single Process? Or Any other ways Dev can minimize mem usage by Chrome significantly.
September 19, 2010 8:57 AM
BrainDedd said...
When I download the Canary installer it installs Google Earth Pro?!?!?!?
September 20, 2010 5:56 AM
Adi said...
Hello !
Adobe released a new flash player version , that will fix a big security isue . Please update chromium 7 !!!
September 21, 2010 5:23 AM
Zan said...
Sites that use the GPU acceleration plugin crash cause the browser to crash. My computer is a Dell Inspiron 1501 (ATI Radeon Xpress)
September 21, 2010 6:58 PM
Jonas N said...
Thanks for giving this some attention!
I love how Chrome is a cross-platform browser too, and that you seem to intend to bring this feature in a cross-platform fashion. :)
Hopefully, all about this will work out well for Mozilla too, so that we'll have at least two browsers than can do this, and build further confidence for game developers looking at the web for their products. :)
IE 9 unfortunately doesn't do much there to help in my opinion, since it's not even going to be out for Windows XP, much less Linux or Mac.
September 22, 2010 3:46 AM
Post a Comment