View Full Version : How to use extensions?
05-22-2008, 03:35 AM
I'm new to using extensions with OpenGL.
Can anyone explain to me how to use an existing extension?
Perhaps you could use the GL_EXT_texture_compression_s3tc extension as en example since I need to use it.
Note: The device I'm developing for supports this extension
05-22-2008, 06:08 AM
This is explained in the Wiki, Getting Started
If it's not clear, ask questions then.
05-22-2008, 07:22 AM
Library to make life easier:
You have access to all OpenGL functions and extensions in the linking part of your program. You only need to call glewInit() after creating the OpenGL context, and before use extensions call you need to check :
/* It is safe to use the ARB_vertex_program extension here. */
if (glewIsSupported("GL_VERSION_1_4 GL_ARB_point_sprite"))
/* Great, we have OpenGL 1.4 + point sprites. */
You can mix it and is better than other APIs like Windows GL or SDL. Here is an example with FBOs:
Is an EclipseProject, you need SDL libs for run it, but you can check the source code. I don't make use of glewIsExtensionAvailable() beacuse I already know my card supports it, but you should add inside the method 'initializeGL()'
Powered by vBulletin® Version 4.2.0 Copyright © 2013 vBulletin Solutions, Inc. All rights reserved.