summaryrefslogtreecommitdiff
path: root/src/gallium/drivers/r300/r300_texture.c
diff options
context:
space:
mode:
authorMarek Olšák <maraeo@gmail.com>2010-07-14 01:59:57 +0200
committerMarek Olšák <maraeo@gmail.com>2010-07-16 08:51:16 +0200
commitfe3caa91d3f637bf9cf9f9e7adb992aa8c7ef8e4 (patch)
treead13a3ebec02d124511d6897402b8b3fdd5835e2 /src/gallium/drivers/r300/r300_texture.c
parent5f9d7bb2425aee65e75667953a6cc304072f2b11 (diff)
r300g: rebuild winsys and command submission to support multiple contexts
Diffstat (limited to 'src/gallium/drivers/r300/r300_texture.c')
-rw-r--r--src/gallium/drivers/r300/r300_texture.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/src/gallium/drivers/r300/r300_texture.c b/src/gallium/drivers/r300/r300_texture.c
index e8b1d67007..5750bc4329 100644
--- a/src/gallium/drivers/r300/r300_texture.c
+++ b/src/gallium/drivers/r300/r300_texture.c
@@ -908,7 +908,8 @@ static unsigned r300_texture_is_referenced(struct pipe_context *context,
struct r300_context *r300 = r300_context(context);
struct r300_texture *rtex = (struct r300_texture *)texture;
- if (r300->rws->is_buffer_referenced(r300->rws, rtex->buffer, R300_REF_CS))
+ if (r300->rws->cs_is_buffer_referenced(r300->cs,
+ rtex->buffer, R300_REF_CS))
return PIPE_REFERENCED_FOR_READ | PIPE_REFERENCED_FOR_WRITE;
return PIPE_UNREFERENCED;
@@ -935,8 +936,9 @@ static boolean r300_texture_get_handle(struct pipe_screen* screen,
return FALSE;
}
- return rws->buffer_get_handle(rws, tex->buffer, whandle,
- r300_texture_get_stride(r300_screen(screen), tex, 0));
+ return rws->buffer_get_handle(rws, tex->buffer,
+ r300_texture_get_stride(r300_screen(screen), tex, 0),
+ whandle);
}
struct u_resource_vtbl r300_texture_vtbl =
@@ -1005,8 +1007,8 @@ struct pipe_resource* r300_texture_create(struct pipe_screen* screen,
R300_DOMAIN_GTT :
R300_DOMAIN_VRAM | R300_DOMAIN_GTT;
- tex->buffer = rws->buffer_create(rws, 2048, base->bind, tex->domain,
- tex->size);
+ tex->buffer = rws->buffer_create(rws, tex->size, 2048, base->bind,
+ base->usage, tex->domain);
if (!tex->buffer) {
FREE(tex);
@@ -1014,9 +1016,8 @@ struct pipe_resource* r300_texture_create(struct pipe_screen* screen,
}
rws->buffer_set_tiling(rws, tex->buffer,
- tex->pitch[0] * util_format_get_blocksize(tex->b.b.format),
- tex->microtile,
- tex->macrotile);
+ tex->microtile, tex->macrotile,
+ tex->pitch[0] * util_format_get_blocksize(tex->b.b.format));
return (struct pipe_resource*)tex;
}
@@ -1176,9 +1177,8 @@ r300_texture_from_handle(struct pipe_screen* screen,
if (override_zb_flags) {
rws->buffer_set_tiling(rws, tex->buffer,
- tex->pitch[0] * util_format_get_blocksize(tex->b.b.format),
- tex->microtile,
- tex->macrotile);
+ tex->microtile, tex->macrotile,
+ tex->pitch[0] * util_format_get_blocksize(tex->b.b.format));
}
return (struct pipe_resource*)tex;
}