diff --git a/src/osg/BufferObject.cpp b/src/osg/BufferObject.cpp index 840803c18..e191906a1 100644 --- a/src/osg/BufferObject.cpp +++ b/src/osg/BufferObject.cpp @@ -189,12 +189,6 @@ void GLBufferObject::compileBuffer() _extensions->glBufferData(_profile._target, _profile._size, NULL, _profile._usage); } - char* vboMemory = 0; - -#if 0 - vboMemory = extensions->glMapBuffer(_target, GL_WRITE_ONLY_ARB); -#endif - for(BufferEntries::iterator itr = _bufferEntries.begin(); itr != _bufferEntries.end(); ++itr) @@ -205,18 +199,10 @@ void GLBufferObject::compileBuffer() // OSG_NOTICE<<"GLBufferObject::compileBuffer(..) downloading BufferEntry "<<&entry<getModifiedCount(); - if (vboMemory) - memcpy(vboMemory + (GLsizeiptrARB)entry.offset, entry.dataSource->getDataPointer(), entry.dataSize); - else - _extensions->glBufferSubData(_profile._target, (GLintptrARB)entry.offset, (GLsizeiptrARB)entry.dataSize, entry.dataSource->getDataPointer()); + _extensions->glBufferSubData(_profile._target, (GLintptrARB)entry.offset, (GLsizeiptrARB)entry.dataSize, entry.dataSource->getDataPointer()); } } - - // Unmap the texture image buffer - if (vboMemory) _extensions->glUnmapBuffer(_profile._target); - - } void GLBufferObject::deleteGLObject()