summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/rbug/rbug_context.c
diff options
context:
space:
mode:
authorMarek Olšák <[email protected]>2017-04-02 14:30:16 +0200
committerMarek Olšák <[email protected]>2017-05-10 19:00:16 +0200
commitc24c3b94ed29ecd99b1101c74c6c4606f9b5580e (patch)
tree81f6966bc59a68d9867693c65d35fae9bb1d9819 /src/gallium/drivers/rbug/rbug_context.c
parentfe437882ea2d60e91c244cc95beb4b79c615af49 (diff)
gallium: decrease the size of pipe_vertex_buffer - 24 -> 16 bytes
Diffstat (limited to 'src/gallium/drivers/rbug/rbug_context.c')
-rw-r--r--src/gallium/drivers/rbug/rbug_context.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/gallium/drivers/rbug/rbug_context.c b/src/gallium/drivers/rbug/rbug_context.c
index 5d002076b49..91b1ac66ebe 100644
--- a/src/gallium/drivers/rbug/rbug_context.c
+++ b/src/gallium/drivers/rbug/rbug_context.c
@@ -778,8 +778,11 @@ rbug_set_vertex_buffers(struct pipe_context *_pipe,
if (num_buffers && _buffers) {
memcpy(unwrapped_buffers, _buffers, num_buffers * sizeof(*_buffers));
- for (i = 0; i < num_buffers; i++)
- unwrapped_buffers[i].buffer = rbug_resource_unwrap(_buffers[i].buffer);
+ for (i = 0; i < num_buffers; i++) {
+ if (!_buffers[i].is_user_buffer)
+ unwrapped_buffers[i].buffer.resource =
+ rbug_resource_unwrap(_buffers[i].buffer.resource);
+ }
buffers = unwrapped_buffers;
}