So, I talked to you all a while ago about layers, and how we are going to be using it to accelerate composition of web pages across all platforms. There's more news on that front! Recently we landed a first version of the OpenGL layers backend onto trunk (See bug 546517). That backend included all the necessary code to use OpenGL for both image upscaling and YUV to RGB color space conversion.
Currently in general the code using layers is not at a point yet where it can benefit from the hardware layers backend for all rendering. For this reason the OpenGL backend is not used yet for your normal browsing. However as many of you may know the performance of fullscreen HTML5 video is not fantastic at the moment for lesser CPUs. Since fullscreen video in particular needs that extra push over the cliff, we decided to enable the OpenGL layers backend by default specifically for the fullscreen video case. What that means is that we upload the Y, Cb and Cr planes to your GPU, draw them to a fullscreen quad and then combine them to create the RGB image on your monitor. Ultimately what matters is that for those of you using compatible hardware and software it should lead to a big improvement in fullscreen video performance when using our latest Nightlies (get them here) and the upcoming Alpha!
Compatible Hardware And Software?
So, currently there's a little bit of work that still needs to be done to make OpenGL layers work on Mac OS X and Linux, so first of all you'll need Windows. Second of all you will need OpenGL 2 compatible drivers for your graphics hardware. Performance may vary across both hardware and drivers.
Eep! I'm running into issues
If you do run into issues with fullscreen video, do go to http://bugzilla.mozilla.org/ and check if your issue has already been reported. If it hasn't, we're very interested in hearing from you so we can address it as quickly as possible. Don't forget to note your graphics hardware and driver version, as this is invaluable information when trying to diagnose issues.
If you're interested in hearing more about layers, Robert O'Callahan has a very informative blogpost here.
Is there a bug to watch for progress on the Linux support?
Looking forward to trying this out, but I only have one windows test machine. It has no Opengl 2 support, and my attempts to force feed it a driver that did failed miserably (the actual card has no maintained driver).
WebGl on the other hand works great on my Ubuntu box, so clearly no opengl problems there.
Right now full screen ogv has a horrible frame rate on my Linux machine, so I guess I can just keep trying an ogv every day. Still a bug to follow would be nice.
I’ve been playing around with it, unfortunately I’m running into bug 556540 (as general as it is).
My card does OpenGL 2 (It’s an 8600GT with the latest drivers), and my CPU isn’t that bad (1.86Ghz Core 2 Duo). Yet full-screen video stutters and uses 100% CPU.
I have been following the layers work for a while, I’m most interested in seeing how WebGL is going to interact with Direct3D backed layers.
@Alex: As soon as https://bugzilla.mozilla.org/show_bug.cgi?id=557896 lands, we should be better able to help you! This will be soon.
This is slightly off topic for this post, but Microsoft has put up an interesting comparison of browsers against IE9’s hardware acceleration:
It would be interesting to see a comparison against Firefox’s forthcoming Direct2D support, even bearing in mind that a debug build of Firefox wouldn’t necessarily deliver the full performance of a release build.
I saw that the patch just landed on the trunk, so as soon as there’s an hourly with it available I’ll see what it outputs.
I’ve tried the latest hourly, and upon going full screen I get these two messages in the Error Console.
http://localhostr.com/files/69f621/ogl%20Error%20Console.png
One thing I noticed, is that while it’s using 100% CPU, it’s smooth *until* the video controls show up, once they’re being rendered it starts stuttering.
OpenGL?
I thought the idea was to take a Direct2D / DirectDraw approach?
I’ve tried fullscreen video hardware acceleration for the video below in FX3.7alpha4 but the result made me very sad. When unscaling, the video hog whole cpu but keep steady fps, then zooming to fullscreen the video behave like slideshow.
http://www.drumbeat.org/content/web-made-movies-building-better-internet-video
But, i could played this video only hogging half of cpu and keeping steady fps in mplayer using directx(overlay) or opengl rendering mode.
Do FX 3.7a4 use new cairo-gl backend?
http://anholt.livejournal.com/42146.html
–
FX 3.7a4, WinXP SP3, AthlonXp1600+, Geforce3 Ti200(d×8.0, opengl 1.5.5)
@Larz: I’m afraid Hardware Acceleration will not work for your GPU, the GeForce3 series is too old! Firefox does not at the moment use the cairo-gl backend.
latest minefield with todays new microsoft update
helped in ms ie9 preview test i gained around 10 fps in 3 d rendering.