mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-24 19:40:10 +01:00
mesa/st: rename access flag to transfer flag function
Reviewed-by: Marek Olšák <marek.olsak@amd.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14133>
This commit is contained in:
parent
fdd31298d3
commit
a79f5d9016
4 changed files with 9 additions and 5 deletions
|
|
@ -413,7 +413,7 @@ bufferobj_data_mem(struct gl_context *ctx,
|
|||
* \param wholeBuffer is the whole buffer being mapped?
|
||||
*/
|
||||
enum pipe_map_flags
|
||||
st_access_flags_to_transfer_flags(GLbitfield access, bool wholeBuffer)
|
||||
_mesa_access_flags_to_transfer_flags(GLbitfield access, bool wholeBuffer)
|
||||
{
|
||||
enum pipe_map_flags flags = 0;
|
||||
|
||||
|
|
@ -476,8 +476,8 @@ _mesa_bufferobj_map_range(struct gl_context *ctx,
|
|||
assert(offset + length <= obj->Size);
|
||||
|
||||
enum pipe_map_flags transfer_flags =
|
||||
st_access_flags_to_transfer_flags(access,
|
||||
offset == 0 && length == obj->Size);
|
||||
_mesa_access_flags_to_transfer_flags(access,
|
||||
offset == 0 && length == obj->Size);
|
||||
|
||||
/* Sometimes games do silly things like MapBufferRange(UNSYNC|DISCARD_RANGE)
|
||||
* In this case, the the UNSYNC is a bit redundant, but the games rely
|
||||
|
|
|
|||
|
|
@ -97,6 +97,9 @@ _mesa_bufferobj_alloc(struct gl_context *ctx, GLuint id);
|
|||
void
|
||||
_mesa_bufferobj_release_buffer(struct gl_buffer_object *obj);
|
||||
|
||||
enum pipe_map_flags
|
||||
_mesa_access_flags_to_transfer_flags(GLbitfield access, bool wholeBuffer);
|
||||
|
||||
/** Is the given buffer object currently mapped by the GL user? */
|
||||
static inline GLboolean
|
||||
_mesa_bufferobj_mapped(const struct gl_buffer_object *obj,
|
||||
|
|
|
|||
|
|
@ -35,6 +35,7 @@
|
|||
|
||||
|
||||
#include "main/context.h"
|
||||
#include "main/bufferobj.h"
|
||||
#include "main/fbobject.h"
|
||||
#include "main/framebuffer.h"
|
||||
#include "main/glformats.h"
|
||||
|
|
@ -922,7 +923,7 @@ st_MapRenderbuffer(struct gl_context *ctx,
|
|||
GL_MAP_INVALIDATE_RANGE_BIT)) == 0);
|
||||
|
||||
const enum pipe_map_flags transfer_flags =
|
||||
st_access_flags_to_transfer_flags(mode, false);
|
||||
_mesa_access_flags_to_transfer_flags(mode, false);
|
||||
|
||||
/* Note: y=0=bottom of buffer while y2=0=top of buffer.
|
||||
* 'invert' will be true for window-system buffers and false for
|
||||
|
|
|
|||
|
|
@ -569,7 +569,7 @@ st_MapTextureImage(struct gl_context *ctx,
|
|||
GL_MAP_INVALIDATE_RANGE_BIT)) == 0);
|
||||
|
||||
const enum pipe_map_flags transfer_flags =
|
||||
st_access_flags_to_transfer_flags(mode, false);
|
||||
_mesa_access_flags_to_transfer_flags(mode, false);
|
||||
|
||||
map = st_texture_image_map(st, stImage, transfer_flags, x, y, slice, w, h, 1,
|
||||
&transfer);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue