summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/bufferobj.c
diff options
context:
space:
mode:
authorTimothy Arceri <[email protected]>2018-05-18 13:23:15 +1000
committerMarek Olšák <[email protected]>2019-06-28 15:41:14 -0400
commiteec5c01b5efc1ab81bfe1af15855e17e852ed4a3 (patch)
treeb67813005cb177cae6fa35f5471f0ecd362ad1f4 /src/mesa/main/bufferobj.c
parent83ed9485b75c92e269c000a5d184393fbe4cbd77 (diff)
mesa: add support for glNamedBufferStorageEXT
This is available in ARB_buffer_storage when EXT_direct_state_access is present. Reviewed-by: Marek Olšák <[email protected]> Signed-off-by: Marek Olšák <[email protected]>
Diffstat (limited to 'src/mesa/main/bufferobj.c')
-rw-r--r--src/mesa/main/bufferobj.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/mesa/main/bufferobj.c b/src/mesa/main/bufferobj.c
index 6b8a2111a8f..0d350dbabd5 100644
--- a/src/mesa/main/bufferobj.c
+++ b/src/mesa/main/bufferobj.c
@@ -1937,6 +1937,21 @@ _mesa_BufferStorage(GLenum target, GLsizeiptr size, const GLvoid *data,
false, false, false, "glBufferStorage");
}
+void GLAPIENTRY
+_mesa_NamedBufferStorageEXT(GLuint buffer, GLsizeiptr size,
+ const GLvoid *data, GLbitfield flags)
+{
+ GET_CURRENT_CONTEXT(ctx);
+
+ struct gl_buffer_object *bufObj = _mesa_lookup_bufferobj(ctx, buffer);
+ if (!_mesa_handle_bind_buffer_gen(ctx, buffer,
+ &bufObj, "glNamedBufferStorageEXT"))
+ return;
+
+ inlined_buffer_storage(GL_NONE, buffer, size, data, flags, GL_NONE, 0,
+ true, false, false, "glNamedBufferStorageEXT");
+}
+
void GLAPIENTRY
_mesa_BufferStorageMemEXT(GLenum target, GLsizeiptr size,