Detecting HW opengl

Hi!

I’m doing some opengl coding for a couple of different projects.

I one of those projects I’ll use different gfx handling depending on the
gfx hardware in the computer.
Now I’m curious how to detect true hardware accellerated opengl in SDL,
mostly in Linux since X4.x.x automagically
runs software OpenGL if no hardware is available.–
Mvh Fredrik Johnsson, Linux Konsult
?restad Linux & Network Consulting
Tel: 040-12 20 15
Mobil: 0709-16 05 30
Email: fredrikj at orestad-linux.net
Url: http://www.orestad-linux.net

“Fredrik Johnsson” wrote

I’m doing some opengl coding for a couple of different projects.

I one of those projects I’ll use different gfx handling depending on the
gfx hardware in the computer.
Now I’m curious how to detect true hardware accellerated opengl in SDL,
mostly in Linux since X4.x.x automagically
runs software OpenGL if no hardware is available.

i’d look into something like glGetString(GL_RENDERER) or
glGetString(GL_VENDOR) and see if you get something that
doesn’t sound like a SW renderer. of course, this may not
be the best way, but its the only one i can think of :]

Look these:

(Windows)
GL VENDOR:
Microsoft Corporation
GL RENDERER:
GDI Generic
GL VERSION:
1.1.0

AND/OR
(Windows Mesa)
GL VENDOR:
Brian Paul
GL RENDERER:
Mesa Windows
GL VERSION:
1.2 Mesa 3.4.1

AND/OR
(Linux X11)
GL VENDOR:
Brian Paul
GL RENDERER:
Mesa X11
GL VERSION:
1.2 Mesa 3.2.1

I think Apple’s is a software renderer too:

GL VENDOR:
Apple
GL RENDERER:
Generic
GL VERSION:
1.1

So if you do glGetString(GL_RENDERER) or glGetString(GL_VENDOR) and look for
any of the software renderer’s strings, that should tell you.

Note however that 3DFX Voodoo and early S3 cards also use Mesa, and under
the windows MESA it can also be configured to pass through to the microsoft
or SGI software renderer’s._________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com

[ multiples snipped ]

So if you do glGetString(GL_RENDERER) or glGetString(GL_VENDOR) and look for
any of the software renderer’s strings, that should tell you.

For the love of God, this is exactly why you shouldn’t do something as
abysmally naive as this.

There is no demarcation of software vs. hardware
rendering. Yesterday’s hardware rendering is today’s software. One
feature configuration on one piece of hardware is a software fallback
on another. All you can do is time your application and determine if
the rendering/execution went fast enough.

m.On Tue, Aug 07, 2001 at 12:52:26PM -0700, Kisai wrote:


“To be able to trust and rely on another person is
the most valuable gift in this world to give and to receive.”
– Sensei Furuya

There is no demarcation of software vs. hardware

This is especially apparent in the DRI drivers, as any given render function
may be accelerated or fall back to software, depending on the state of the
drivers for that particular day.

See ya!
-Sam Lantinga, Software Engineer, Blizzard Entertainment

…and in a not too distant future, the gamer PC will probablyf be fast
enough to play today’s heaviest OpenGL games on software only OpenGL
implementations.

Remember the days when it was unthinkable to use software rendering in a
scrolling 2D game? :slight_smile:

//David Olofson — Programmer, Reologica Instruments AB

.- M A I A -------------------------------------------------.
| Multimedia Application Integration Architecture |
| A Free/Open Source Plugin API for Professional Multimedia |
----------------------> http://www.linuxaudiodev.com/maia -' .- David Olofson -------------------------------------------. | Audio Hacker - Open Source Advocate - Singer - Songwriter |--------------------------------------> david at linuxdj.com -'On Tuesday 07 August 2001 23:44, Michael Vance wrote:

On Tue, Aug 07, 2001 at 12:52:26PM -0700, Kisai wrote:

[ multiples snipped ]

So if you do glGetString(GL_RENDERER) or glGetString(GL_VENDOR) and
look for any of the software renderer’s strings, that should tell
you.

For the love of God, this is exactly why you shouldn’t do something as
abysmally naive as this.

There is no demarcation of software vs. hardware
rendering. Yesterday’s hardware rendering is today’s software. One
feature configuration on one piece of hardware is a software fallback
on another. All you can do is time your application and determine if
the rendering/execution went fast enough.