I need to access the pointer in st/mesa when I only have pipe_resource.
buf->b.b.height0 = 1;
buf->b.b.depth0 = 1;
buf->b.b.array_size = 1;
+ buf->b.b.user_ptr = ptr;
buf->data = ptr;
buf->free_on_destroy = FALSE;
buffer->base.height0 = 1;
buffer->base.depth0 = 1;
buffer->base.array_size = 1;
+ buffer->base.user_ptr = ptr;
buffer->userBuffer = TRUE;
buffer->data = ptr;
templ.height0 = 1;
templ.depth0 = 1;
templ.flags = 0;
+ templ.user_ptr = ptr;
return noop_resource_create(screen, &templ);
}
buffer->base.width0 = bytes;
buffer->base.height0 = 1;
buffer->base.depth0 = 1;
+ buffer->base.user_ptr = ptr;
buffer->data = ptr;
buffer->status = NOUVEAU_BUFFER_STATUS_USER_MEMORY;
rbuf->b.b.vtbl = &r300_buffer_vtbl;
pipe_reference_init(&rbuf->b.b.b.reference, 1);
rbuf->b.b.b.screen = screen;
+ rbuf->b.b.b.user_ptr = NULL;
rbuf->b.user_ptr = NULL;
rbuf->domain = RADEON_DOMAIN_GTT;
rbuf->buf = NULL;
rbuf->b.b.b.depth0 = 1;
rbuf->b.b.b.array_size = 1;
rbuf->b.b.b.flags = 0;
+ rbuf->b.b.b.user_ptr = ptr;
rbuf->b.b.vtbl = &r300_buffer_vtbl;
rbuf->b.user_ptr = ptr;
rbuf->domain = RADEON_DOMAIN_GTT;
rbuffer->b.b.b = *templ;
pipe_reference_init(&rbuffer->b.b.b.reference, 1);
rbuffer->b.b.b.screen = screen;
+ rbuffer->b.b.b.user_ptr = NULL;
rbuffer->b.b.vtbl = &r600_buffer_vtbl;
rbuffer->b.user_ptr = NULL;
rbuffer->b.b.b.depth0 = 1;
rbuffer->b.b.b.array_size = 1;
rbuffer->b.b.b.flags = 0;
+ rbuffer->b.b.b.user_ptr = ptr;
rbuffer->b.user_ptr = ptr;
rbuffer->buf = NULL;
return &rbuffer->b.b.b;
rbuffer->b.b.b.depth0 = 1;
rbuffer->b.b.b.array_size = 1;
rbuffer->b.b.b.flags = 0;
+ rbuffer->b.b.b.user_ptr = ptr;
rbuffer->b.user_ptr = ptr;
rbuffer->buf = NULL;
return &rbuffer->b.b.b;
spr->base.height0 = 1;
spr->base.depth0 = 1;
spr->base.array_size = 1;
+ spr->base.user_ptr = ptr;
spr->userBuffer = TRUE;
spr->data = ptr;
sbuf->b.b.height0 = 1;
sbuf->b.b.depth0 = 1;
sbuf->b.b.array_size = 1;
+ sbuf->b.b.user_ptr = ptr;
sbuf->swbuf = ptr;
sbuf->user = TRUE;
unsigned bind; /**< bitmask of PIPE_BIND_x */
unsigned flags; /**< bitmask of PIPE_RESOURCE_FLAG_x */
+
+ /* XXX this is only temporary and will be removed once it's not needed */
+ uint8_t *user_ptr; /**< user buffer pointer */
};