summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/mesa/main/bufferobj.c27
-rw-r--r--src/mesa/main/bufferobj.h6
2 files changed, 13 insertions, 20 deletions
diff --git a/src/mesa/main/bufferobj.c b/src/mesa/main/bufferobj.c
index 961871c91d5..76e035f9a29 100644
--- a/src/mesa/main/bufferobj.c
+++ b/src/mesa/main/bufferobj.c
@@ -2379,11 +2379,10 @@ _mesa_CopyNamedBufferSubData(GLuint readBuffer, GLuint writeBuffer,
}
-void *
-_mesa_map_buffer_range(struct gl_context *ctx,
- struct gl_buffer_object *bufObj,
- GLintptr offset, GLsizeiptr length,
- GLbitfield access, const char *func)
+static void *
+map_buffer_range(struct gl_context *ctx, struct gl_buffer_object *bufObj,
+ GLintptr offset, GLsizeiptr length, GLbitfield access,
+ const char *func)
{
void *map;
GLbitfield allowed_access;
@@ -2586,8 +2585,8 @@ _mesa_MapBufferRange(GLenum target, GLintptr offset, GLsizeiptr length,
if (!bufObj)
return NULL;
- return _mesa_map_buffer_range(ctx, bufObj, offset, length, access,
- "glMapBufferRange");
+ return map_buffer_range(ctx, bufObj, offset, length, access,
+ "glMapBufferRange");
}
void * GLAPIENTRY
@@ -2608,13 +2607,13 @@ _mesa_MapNamedBufferRange(GLuint buffer, GLintptr offset, GLsizeiptr length,
if (!bufObj)
return NULL;
- return _mesa_map_buffer_range(ctx, bufObj, offset, length, access,
- "glMapNamedBufferRange");
+ return map_buffer_range(ctx, bufObj, offset, length, access,
+ "glMapNamedBufferRange");
}
/**
* Converts GLenum access from MapBuffer and MapNamedBuffer into
- * flags for input to _mesa_map_buffer_range.
+ * flags for input to map_buffer_range.
*
* \return true if the type of requested access is permissible.
*/
@@ -2653,8 +2652,8 @@ _mesa_MapBuffer(GLenum target, GLenum access)
if (!bufObj)
return NULL;
- return _mesa_map_buffer_range(ctx, bufObj, 0, bufObj->Size, accessFlags,
- "glMapBuffer");
+ return map_buffer_range(ctx, bufObj, 0, bufObj->Size, accessFlags,
+ "glMapBuffer");
}
void * GLAPIENTRY
@@ -2673,8 +2672,8 @@ _mesa_MapNamedBuffer(GLuint buffer, GLenum access)
if (!bufObj)
return NULL;
- return _mesa_map_buffer_range(ctx, bufObj, 0, bufObj->Size, accessFlags,
- "glMapNamedBuffer");
+ return map_buffer_range(ctx, bufObj, 0, bufObj->Size, accessFlags,
+ "glMapNamedBuffer");
}
diff --git a/src/mesa/main/bufferobj.h b/src/mesa/main/bufferobj.h
index 259de9465a1..f9d887465dc 100644
--- a/src/mesa/main/bufferobj.h
+++ b/src/mesa/main/bufferobj.h
@@ -158,12 +158,6 @@ _mesa_copy_buffer_sub_data(struct gl_context *ctx,
GLintptr readOffset, GLintptr writeOffset,
GLsizeiptr size, const char *func);
-extern void *
-_mesa_map_buffer_range(struct gl_context *ctx,
- struct gl_buffer_object *bufObj,
- GLintptr offset, GLsizeiptr length,
- GLbitfield access, const char *func);
-
extern void
_mesa_flush_mapped_buffer_range(struct gl_context *ctx,
struct gl_buffer_object *bufObj,