I am using the Ogre3d engine supporting OpenGL mode.
I have an object called Chunk
which creates an Ogre::ManualObject
. Because the creation of the ManualObject
takes a bit of time I put the task onto a new thread.
Unfortunately, after threading the creation of the ManualObject
I am now getting the following OgreException:
"Cannot create GL vertex buffer in GLHardwareVertexBuffer::GLHardwareVertexBuffer"
I looked into the code and it is failing at this stage:
glGenBuffersARB( 1, &mBufferId );
if (!mBufferId)
{
OGRE_EXCEPT(Exception::ERR_INTERNAL_ERROR,
"Cannot create GL vertex buffer",
"GLHardwareVertexBuffer::
}
This suggests that glGenBuffersARB() is not properly populating mBufferId.
I can't figure out what is causing this, any suggestions?