Archived

This topic is now archived and is closed to further replies.

automated extension linking with GLee (V1.1 is up)

This topic is 5471 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

Recommended Posts

Edit: Version 1.1 is up. It's a bit neater internally, and it gives detailed error reporting (see the readme). I've just finished writing GLee, the OpenGL Easy Extension library. It's developed using a little program I made called GLeeGen, which automatically writes the code to link and query every OpenGL extension based on the contents of glExt.h and wglExt.h. As far as I know, it supports every GL and WGL extension in the registry. To use it, you just have to link to glee.lib, and include glee.h in your project. Once linked, it's pretty straightforward to use:
...create openGL window etc...
GLeeInit();   //extensions can be used from here onwards

...
//Does GL_ARB_point_parameter exist?

if (GLEE_ARB_point_parameter)
{
glPointParameterfARB(...);
}

//Is OpenGL 1.3 supported?

if (GLEE_VERSION_1_3)
{
...
}
I've made the license as non-restrictive as possible in order to make it useful to everyone. The only thing I'm asking is you give credit where due. Let me know if you have any comments/bug reports etc. I've only tested this on my Radeon 9700, so more testing would be helpful. Links: Note: You will need wglext.h and glext.h from sgi. [EDIT: updated for version 1.01: The hDC is no longer required (thanks davepermen)] [edited by - benjamin bunny on August 19, 2003 6:47:49 AM] [edited by - benjamin bunny on August 23, 2003 12:48:36 PM]

Share on other sites
Congrats on finishing this, but I thought I should let you know that there is already a library that does what yours does... at least from what you''ve put down so far. Have you heard of Lev Povalahev''s extension loading library? Take a look at it if you haven''t. Maybe you could post what makes yours unique or different.

Share on other sites
I'm aware of other similar libs such as extgl, GLEW and GLuX.

The main advantage of my lib is it supports every extension in the registry. It's automatically generated, so every extension in glext.h and wglext.h is supported as soon as glext.h and wglext.h are updated; I just have to run GleeGen.exe and rebuild. I believe GLEW works in a similar way, however the licenses are more restrictive.

I plan to support it right up through OpenGL 2.0 and beyond.

____________________________________________________________
www.elf-stone.com

[edited by - benjamin bunny on August 18, 2003 5:19:28 PM]

Share on other sites
great. but why do you need the hdc?

"take a look around" - limp bizkit

Share on other sites
To pass to wglGetExtensionsStringARB to get the WGL extensions.

Share on other sites
others don''t need it as well.. dunno.. it would look much more clean.. and as i use sdl i normally don''t access the hdc myself at all..

wglGetCurrentDC or so should give you all you need, not?

"take a look around" - limp bizkit

Share on other sites
Ah, wglGetCurrentDC, that's what I needed. I was looking in the win32 API docs before. Thanks. It's fixed now.

[edited by - benjamin bunny on August 19, 2003 6:31:51 AM]

Share on other sites
Cool! I''m using extgl for my projects right now, but I''ll give it a try. Also, maybe it would be helpful to add links to your libray and extgl as well as others to the forum faqs, since every so often there are questions on good ways to load extensions.

Share on other sites
What, you mean abuse my moderator privilages to pimp my own software. Done!

____________________________________________________________

Share on other sites
lol, no conflict of interest here

[edited by - _walrus on August 19, 2003 11:57:19 AM]

1. 1
2. 2
frob
15
3. 3
4. 4
5. 5

• 13
• 13
• 14
• 68
• 15
• Forum Statistics

• Total Topics
632137
• Total Posts
3004314

×