The Linux Gamers" How-To

106 9

9.1. Hardware Acceleration Problems


XFree86 4.x provides a more centralized and self-contained approach to video. Much of the funkyness like kernel modules for non-root access of video boards is, thankfully, gone.

9.1.1. Hardware acceleration isn't working at all


If you're getting like 1 fps, then your system isn't using hardware 3D acceleration. There's one of two things that can be going on.
  • Your 3D system is misconfigured (more likely)


  • Game X is misconfigured (less likely)

The first step is to figure out which one is happening.
  • If you have X 4.0 (X 3.* users procede to step 2), look at the output of X -probeonly . You'll see:

       

    (II) XXXXXX: direct rendering enabled
    or

       

    (II) XXXXXX: direct rendering disabled
    where XXXXXXX depends on which video card you have. If direct rendering is disabled, then your X configuration is definitely faulty. Your game is not at fault. You need to figure out why DRI is disabled. The most important tool for you to use at this point is the 'DRI Users Guide'. It is an excellently written document that gives you step by step information on how to get DRI set up correctly on your machine. A copy is kept at http://www.xfree86.org/4.0/DRI.html .

    Note that if you pass this test, your system is CAPABLE of direct rendering. Your libraries can still be wrong. So procede to step 2.
  • There is a program called glxgears which comes with the "mesademos" package. You can get mesademos with Debian ( apt-get install mesademos ) or you can hunt for the rpm on http://www.rpmfind.net . You can also download and compile the source yourself from the mesa homepage.

    Running glxgears will show some gears turning. The xterm from which you run glxgears will display "X frames in Y seconds = X/Y FPS". You can compare your system to the list of benchmarks below.

       

    CPU TYPE VIDEO CARD X VERSION AVERAGE FPS
    Compiling Mesa and DRI modules yourself can increase your FPS by 15 FPS; quite a performance boost! So if your number is, say, about 20 FPS slower than a comparable machine, chances are that glxgears is falling back on software rendering. In other words, your graphics card isn't 3D accelerating graphics.

    More important than FPS is having a constant FPS for small and large windows. If hardware acceleration is working, the FPS for glxgears should be nearly independent of window size. If it's not, then you're not getting hardware acceleration.

    * License

    * The Linux Gamers' How-To Index
    Source...
    Subscribe to our newsletter
    Sign up here to get the latest news, updates and special offers delivered directly to your inbox.
    You can unsubscribe at any time

    Leave A Reply

    Your email address will not be published.