mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-08 13:28:06 +02:00
iris: resolve before transfer maps
This commit is contained in:
parent
c53a67d469
commit
f8aa9aa353
2 changed files with 12 additions and 3 deletions
|
|
@ -1061,6 +1061,12 @@ iris_transfer_map(struct pipe_context *ctx,
|
|||
(usage & PIPE_TRANSFER_MAP_DIRECTLY))
|
||||
return NULL;
|
||||
|
||||
if (resource->target != PIPE_BUFFER) {
|
||||
iris_resource_access_raw(ice, &ice->batches[IRIS_BATCH_RENDER], res,
|
||||
level, box->z, box->depth,
|
||||
usage & PIPE_TRANSFER_WRITE);
|
||||
}
|
||||
|
||||
if (!(usage & PIPE_TRANSFER_UNSYNCHRONIZED)) {
|
||||
for (int i = 0; i < IRIS_BATCH_COUNT; i++) {
|
||||
if (iris_batch_references(&ice->batches[i], res->bo))
|
||||
|
|
|
|||
|
|
@ -298,12 +298,15 @@ iris_resource_access_raw(struct iris_context *ice,
|
|||
struct iris_batch *batch,
|
||||
struct iris_resource *res,
|
||||
uint32_t level, uint32_t layer,
|
||||
uint32_t num_layers,
|
||||
bool write)
|
||||
{
|
||||
iris_resource_prepare_access(ice, batch, res, level, 1, layer, 1,
|
||||
iris_resource_prepare_access(ice, batch, res, level, 1, layer, num_layers,
|
||||
ISL_AUX_USAGE_NONE, false);
|
||||
if (write)
|
||||
iris_resource_finish_write(ice, res, level, layer, 1, ISL_AUX_USAGE_NONE);
|
||||
if (write) {
|
||||
iris_resource_finish_write(ice, res, level, layer, num_layers,
|
||||
ISL_AUX_USAGE_NONE);
|
||||
}
|
||||
}
|
||||
|
||||
enum isl_aux_usage iris_resource_texture_aux_usage(struct iris_context *ice,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue