void GraphicsBuffer::UnMap()
{
GLenum target = BufferTypeToGLType(m_buffer_type);
+
+ // If we're not mapped, unmapping is a no-op.
+ if (!m_map_pointer)
+ return;
if (m_faking_map)
{
glBindBuffer(BufferTypeToGLType(m_buffer_type), m_buffer_handle);
}
+void GraphicsBuffer::BindRange(size_t start, size_t size) const
+{
+ glBindBufferRange(BufferTypeToGLType(m_buffer_type), 0, m_buffer_handle, start, size);
+}