mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 20:28:04 +02:00
zink: propagate valid buffer range to real buffer when mapping staging
cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30107>
(cherry picked from commit fa210726b6)
This commit is contained in:
parent
92e59d71cd
commit
722a7f589d
2 changed files with 6 additions and 2 deletions
|
|
@ -244,7 +244,7 @@
|
|||
"description": "zink: propagate valid buffer range to real buffer when mapping staging",
|
||||
"nominated": true,
|
||||
"nomination_type": 0,
|
||||
"resolution": 0,
|
||||
"resolution": 1,
|
||||
"main_sha": null,
|
||||
"because_sha": null,
|
||||
"notes": null
|
||||
|
|
|
|||
|
|
@ -2432,9 +2432,13 @@ overwrite:
|
|||
}
|
||||
}
|
||||
trans->base.b.usage = usage;
|
||||
if (usage & PIPE_MAP_WRITE)
|
||||
if (usage & PIPE_MAP_WRITE) {
|
||||
util_range_add(&res->base.b, &res->valid_buffer_range, box->x, box->x + box->width);
|
||||
|
||||
struct zink_resource *orig_res = zink_resource(trans->base.b.resource);
|
||||
util_range_add(&orig_res->base.b, &orig_res->valid_buffer_range, box->x, box->x + box->width);
|
||||
}
|
||||
|
||||
success:
|
||||
/* ensure the copy context gets unlocked */
|
||||
if (ctx == screen->copy_context)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue