Ubuntu – Force Enable Hardware Acceleration in Firefox

14.04firefoxhardware acceleration

Currently, in about:support (Firefox 30) the "Graphics" section states the following:

enter image description here
Now, I know that Firefox has (for whatever reason) disabled the hardware accelerated features for Linux users. However, as stated in this site, it should be possible to force enable it. So far, I have:

  • Set layers.acceleration.force-enabled and layers.offmainthreadcomposition.enabled to true.
  • Set the environment variable MOZ_USE_OMTC=1

It doesn't work, and the hardware acceleration remains disabled. Is there another way to force-enable hardware acceleration (performance is horrible on my computer)? Or am I just doing it wrong?

Best Answer

I try this as a answer even if the question actually gave the answer to me. I had problems setting up the environment variable - because it actually went away as soon as i closed the console. It worked when I started Firefox on the same console I used the export command but nothing else. I tried setting it in bash and zsh. Then I found a solution and now what is described in the question works perfectly for me.

  1. Check if Hardware acceleration is actually enabled in Firefox by visiting about:support looking for "GPU Accelerated Windows 1/1 OpenGL (OMTC)" under graphics. If this shows 1/1 you can stop right here, you not need this tweak. But if it shows 0/1 you can force it on ...
  2. Open about:config in Firefox (url bar)
  3. Set layers.acceleration.force-enabled and layers.offmainthreadcomposition.enabled to true
  4. Run sudo bash -c "echo export MOZ_USE_OMTC=1 >> /etc/X11/Xsession.d/90environment" to set the enviorment variable globally for X (Is no longer needed for up to date Firefox versions)
  5. Reboot and check about:support for "GPU Accelerated Windows 1/1 ..."

enter image description here