How to know if direct render is abailable

Hi,

I want to know for a program running in linux if direct rendering is abailable.
I believe glXIsDirect does the trick.

The question is, can I call this function within a SDL context?

Regards.

SDL under X11 uses GLX internally for OpenGL, so I would assume so. I
can think of two caveats, though.

  1. You’ll need a Display and a GLXContext to pass to the function, and
    I’m not sure how you’d get your hands on those.
  2. If you’re taking “direct rendering” to mean "hardware accelerated,"
    remember that indirect rendering can be accelerated too. For example,
    if X11 forwarding is in effect, rendering may be hardware accelerated
    (and reasonably fast) but glXIsDirect will return False. (I’m not sure
    how AIGLX fits in.)
    -:sigma.SBOn Nov 15, 2007 6:55 PM, David Roguin wrote:

I want to know for a program running in linux if direct rendering is abailable.
I believe glXIsDirect does the trick.
The question is, can I call this function within a SDL context?