mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-09 04:38:03 +02:00
gallium: Remove temporary hack for the absence of a discard flag.
PIPE_BUFFER_USAGE_DISCARD flag now exists.
This commit is contained in:
parent
0ae076bf40
commit
13c2475339
1 changed files with 0 additions and 7 deletions
|
|
@ -63,13 +63,6 @@ pipe_buffer_map(struct pipe_screen *screen,
|
|||
if(screen->buffer_map_range) {
|
||||
unsigned offset = 0;
|
||||
unsigned length = buf->size;
|
||||
|
||||
/* XXX: Actually we should be using/detecting DISCARD
|
||||
* instead of assuming that WRITE implies discard */
|
||||
if((usage & PIPE_BUFFER_USAGE_CPU_WRITE) &&
|
||||
!(usage & PIPE_BUFFER_USAGE_DISCARD))
|
||||
usage |= PIPE_BUFFER_USAGE_CPU_READ;
|
||||
|
||||
return screen->buffer_map_range(screen, buf, offset, length, usage);
|
||||
}
|
||||
else
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue