[buffer_storage] Add the CLIENT_STORAGE_BIT since we access the buffer more frequently on the client side than the server side. That is exactly what the hint is for.

This commit is contained in:
Ryan Houdek 2013-12-27 22:58:36 -06:00
parent d8ceb97a60
commit 77ba051361
1 changed files with 2 additions and 1 deletions

View File

@ -220,8 +220,9 @@ void StreamBuffer::Init()
// PERSISTANT_BIT to make sure that the buffer can be used while mapped
// COHERENT_BIT is set so we don't have to use a MemoryBarrier on write
// CLIENT_STORAGE_BIT is set since we access the buffer more frequently on the client side then server side
glBufferStorage(m_buffertype, m_size, NULL,
GL_MAP_WRITE_BIT | GL_MAP_PERSISTENT_BIT | GL_MAP_COHERENT_BIT);
GL_MAP_WRITE_BIT | GL_MAP_PERSISTENT_BIT | GL_MAP_COHERENT_BIT | GL_CLIENT_STORAGE_BIT);
pointer = (u8*)glMapBufferRange(m_buffertype, 0, m_size,
GL_MAP_WRITE_BIT | GL_MAP_PERSISTENT_BIT | GL_MAP_COHERENT_BIT);
if(!pointer)