diff options
author | Marek Olšák <[email protected]> | 2013-01-02 20:23:57 +0100 |
---|---|---|
committer | Marek Olšák <[email protected]> | 2013-01-04 21:08:28 +0100 |
commit | d4ff72b9447dcff29c51bcb8b037eb4a53bcc040 (patch) | |
tree | 5ab2f4884e2d7ba5f1861ffcd67660563010364f /src/gallium/drivers | |
parent | 06f67e75ee7158e7f13860d07785e1cf3f8f4b13 (diff) |
r300g: don't set PIPE_BIND flags for internal textures
Diffstat (limited to 'src/gallium/drivers')
-rw-r--r-- | src/gallium/drivers/r300/r300_context.c | 1 | ||||
-rw-r--r-- | src/gallium/drivers/r300/r300_transfer.c | 21 |
2 files changed, 1 insertions, 21 deletions
diff --git a/src/gallium/drivers/r300/r300_context.c b/src/gallium/drivers/r300/r300_context.c index 048f810b6b4..878b52f764f 100644 --- a/src/gallium/drivers/r300/r300_context.c +++ b/src/gallium/drivers/r300/r300_context.c @@ -428,7 +428,6 @@ struct pipe_context* r300_create_context(struct pipe_screen* screen, rtempl.target = PIPE_TEXTURE_2D; rtempl.format = PIPE_FORMAT_I8_UNORM; - rtempl.bind = PIPE_BIND_SAMPLER_VIEW; rtempl.usage = PIPE_USAGE_IMMUTABLE; rtempl.width0 = 1; rtempl.height0 = 1; diff --git a/src/gallium/drivers/r300/r300_transfer.c b/src/gallium/drivers/r300/r300_transfer.c index fbae2df52b9..6ad08c6740e 100644 --- a/src/gallium/drivers/r300/r300_transfer.c +++ b/src/gallium/drivers/r300/r300_transfer.c @@ -120,35 +120,16 @@ r300_texture_transfer_map(struct pipe_context *ctx, os_break(); } + memset(&base, 0, sizeof(base)); base.target = PIPE_TEXTURE_2D; base.format = texture->format; base.width0 = box->width; base.height0 = box->height; base.depth0 = 1; base.array_size = 1; - base.last_level = 0; - base.nr_samples = 0; base.usage = PIPE_USAGE_STAGING; - base.bind = 0; - if (usage & PIPE_TRANSFER_READ) { - base.bind |= PIPE_BIND_SAMPLER_VIEW; - } - if (usage & PIPE_TRANSFER_WRITE) { - base.bind |= PIPE_BIND_RENDER_TARGET; - } base.flags = R300_RESOURCE_FLAG_TRANSFER; - /* For texture reading, the temporary (detiled) texture is used as - * a render target when blitting from a tiled texture. */ - if (usage & PIPE_TRANSFER_READ) { - base.bind |= PIPE_BIND_RENDER_TARGET; - } - /* For texture writing, the temporary texture is used as a sampler - * when blitting into a tiled texture. */ - if (usage & PIPE_TRANSFER_WRITE) { - base.bind |= PIPE_BIND_SAMPLER_VIEW; - } - /* Create the temporary texture. */ trans->linear_texture = r300_resource( ctx->screen->resource_create(ctx->screen, |