Skip to main content
gamedev.net
🔒 Locked

Buffer Object

Started by Simplicity 2 replies 750+ views
Original Post
Simplicity
Simplicity
Hi, I'm trying to do buffer object using Mesa3D 6.4.2 on Fedora Core 5. However, when I call glGenBuffers, it doesn't do anything to the array I put in. For example

GLuint Buf = 0;
glGenBuffers( 1, &Buf );
//Buf is still = 0

GLuint Buffers[5];
for ( int i = 0; i < 5; i++ ) { Buffers = 10; }
glGenBuffers( 5, Buffers );
//all elements are still 10

In other words, glGenBuffers does nothing. I'm using glXGetProcAddress to retrieve the function pointer to glGenBuffers by the way. I put it in a wrapper like so:

class GLHelper
{
public:
void* GetProcAddr( std::string Name ) { return( (void*)glXGetProcAddress( (const GLubyte*)Name.c_str() ) ); }
};

When I'm running this code under Windows, everything is ok, except that I use wglGetProcAddress instead. Has anyone has this problem or know how to solve it? Thanks
deavik
deavik
I've had issues with Nvidia's drivers (77.xx, I think) but it's something the newest drivers have corrected I think. The problem was with the version of GLX - glXGetProcAddress is itself, you see, part of an ARB extension. To get it to work I had to use glXGetProcAddressARB, whch worked. You can try it if you want.

BTW, I've never used the pristine Mesa3D library - I've heard it's all done in software, is that true?
Simplicity
Simplicity
I tried glXGetProcAddressARB and still doesn't work.

Mesa3D is software if you don't compile with DRI.

How do I get other implementations of OpenGL for Linux other than Mesa3D? I'm still confuse about ATI and Nvidia driver stuff.

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.