PDA

View Full Version : opengl32.a, cygwin, VBOs installation problems



Stuart McDonald
06-26-2006, 06:08 PM
Hi there,

I've got a program that I've been working on and off on for some time trying out various things. I'm compiling under cygwin and using VBOs.

I just updated my cygwin installation and now my opengl32.a doesn't contain the VBO functions glBufferData etc. and my w32api/gl*.h headers don't have the prototypes.

As far as I can see there are no w32api versions of these that support the VBO functions. I can only assume that when I first set it all up (about a year ago) I had problems getting it to work and copied over the above files with some library that I must have downloaded or compiled from somwhere (not very smart I know).

I'm pretty sure it wasn't using Mesa3D, but I could be wrong. I've tried that and the headers and libGL.a do have the VBO functions, but now my glut functions and undeclared at link time. Though I can't see why since nm on glut32.a shows they are there.

Basically I've stuffed my installation (which I seem to have hacked together in the first place) and I'm looking for help to get it back. My makefile had
-l glut32 -l glu32 -l opengl32

I've installed Mesa3d and changed it to
-l glut32 -l glu32 -L /usr/local/lib -l GL
but that now gives me
'undefined reference to _glutInit'
and all the other glut functions.

I don't really understand the whole w32api/opengl/GL/Mesa/glut/freeGlut/etc thing so any help would be much appreciated.

Cheers,
Stuart.

ZbuffeR
06-27-2006, 02:13 AM
I just updated my cygwin installation and now my opengl32.a doesn't contain the VBO functions glBufferData etc. and my w32api/gl*.h headers don't have the prototypes.Under Windows and in genereal, you should not rely on having direct acess to functions past GL 1.1, instead use an extension loading library or do it yourself.
If it worked before, you most certainly had software acceleration through mesa.

Stuart McDonald
06-28-2006, 10:59 PM
Fixed it. All I must have done is copy the w32api files (except glext.h) into /usr/include/GL (yes, yes I know!)

So I simply changed my compile to have

-I /usr/local/include/w32api

and replaced the w32api/glext.h with the latest. Not exacly happy with that, but I can't see how to do it other than have my own local glext.h.

I'm not using Mesa. If GL_VERSION 1.5 is not available then I use

glutExtensionSupported("GL_ARB_vertex_buffer_object")

and then wglGetGetProcAddress.

--Stuart.