1. Home
  2. Internet Tips
  3. Enable firefox hardware accelerated graphics

Enable Firefox Hardware Accelerated Graphics

Over the past few days, news have been surfacing of the Mozilla developers bringing performance improvements to the Firefox web browser, specifically in the regions of JavaScript and hardware-rendered graphics. Over the last couple of days, blog posts by developers like Asa Dotzler have indicated the upcoming new JavaScript engine, the JaegerMonkey, and the landing of DirectWrite and Direct2D in Firefox nightly builds, bringing hardware acceleration to text and 2-D graphics for Windows 7 and Vista.

JavaScript engines lie at the core of any capable web browser, and the better a browser can handle JS throughout the web, the better user experience it will deliver. The biggest competitors in this domain have been Google’s Chrome and Mozilla Firefox, and Chrome has had the upper hand for most part. Luckily for Firefox, the JaegerMonkey engine is believed to improve the JavaScript performance of Firefox by 30% to 45%, with room for lots of further improvements.

You may want to check out this blog post by David Mandelin, which offers specific high-level information on starting the JaegerMonkey engine, and this article by David Anderson providing an overview of the how and what the work is being done in this front.

The second improvement, that is, addition of browser’s capability to use Windows Vista’s and Windows 7’s DirectWrite and Direct2D APIs would be more interesting to watch, since Asa Dotzler claims that even the fonts look really great with DirectWrite enabled. For those of our adventurous readers that want to try it out for themselves, you can download the latest nightly build, and make the following changes to enable these features.

  1. Enter ‘about:config’
  2. Click through the warning, if necessary
  3. Enter gfx.font in the ‘Filter’ box
  4. Double-click on ‘gfx.font_rendering.directwrite.enabled’ to set it to true
  5. Below this, right click and select New > Integer to add a pref setting
  6. Enter ‘mozilla.widget.render-mode’ for the preference name, 6 for the value
  7. Restart

(To disable, set gfx.font_rendering.directwrite.enabled to false, delete mozilla.widget.render-mode, then restart.)

Note: If the above does not make sense to you, please do not try this. This is a developers’ release, and may render your browser unstable. It would be better to backup your browser first.

It may take a while for these features to get integrated in any final release of the Firefox browser, but once it does it would be interesting to watch how Firefox compares with its competitors (Chrome, for example), that are already ahead of it in terms of JavaScript rendering.

233 Comments

  1. Just a note, hardware acceleration will not work on Pre-Vista OS’s, as it uses DirectWrite (Font API) and Direct2D (replacement for DirectDraw, requires a DX10.1 or higher video card for hardware acceleration). You can still use the advantages of DirectWrite font kerning even if your video card does not support DX10.1/11 (though you need Vista/7), but you will not be able to use hardware acceleration, without well, hardware support 😉

  2. Seems Interesting! But HW Acclerated Graphics are surely to improve Visuals With its Anti alaising and many more techniques 😀 Kudos to Mozilla!

    • You're right about that. We look forward to these changes in Firefox, since Chrome is quickly becoming a threatening competitor on this ground.