From 28d7335810c2419fa6931260c30717dcf618109a Mon Sep 17 00:00:00 2001 From: Fredrik Höglund Date: Fri, 15 Nov 2013 19:47:20 +0100 Subject: mesa: Add helper functions for looking up multiple buffers v2: Document the difference between _mesa_lookup_bufferobj() and _mesa_multi_bind_lookup_bufferobj(). v3: Don't create the buffer objects when they don't exist. Reviewed-by: Brian Paul (v2) Reviewed-by: Ian Romanick (v2) --- src/mesa/main/bufferobj.h | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'src/mesa/main/bufferobj.h') diff --git a/src/mesa/main/bufferobj.h b/src/mesa/main/bufferobj.h index e1b2a565a98..0779605c08b 100644 --- a/src/mesa/main/bufferobj.h +++ b/src/mesa/main/bufferobj.h @@ -86,6 +86,20 @@ _mesa_update_default_objects_buffer_objects(struct gl_context *ctx); extern struct gl_buffer_object * _mesa_lookup_bufferobj(struct gl_context *ctx, GLuint buffer); +extern struct gl_buffer_object * +_mesa_lookup_bufferobj_locked(struct gl_context *ctx, GLuint buffer); + +extern void +_mesa_begin_bufferobj_lookups(struct gl_context *ctx); + +extern void +_mesa_end_bufferobj_lookups(struct gl_context *ctx); + +extern struct gl_buffer_object * +_mesa_multi_bind_lookup_bufferobj(struct gl_context *ctx, + const GLuint *buffers, + GLuint index, const char *caller); + extern void _mesa_initialize_buffer_object(struct gl_context *ctx, struct gl_buffer_object *obj, -- cgit v1.2.3