mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-07 09:18:04 +02:00
zink: enable unsynchronized texture uploads using staging buffers
by not returning busy for non-HIC unsynchronized texture uploads, the GL frontend will fall through to directly access the unsynchronized cmdbuf Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25624>
This commit is contained in:
parent
846a5ea224
commit
9a98d6714d
1 changed files with 2 additions and 7 deletions
|
|
@ -4918,14 +4918,9 @@ zink_context_is_resource_busy(struct pipe_screen *pscreen, struct pipe_resource
|
|||
{
|
||||
struct zink_screen *screen = zink_screen(pscreen);
|
||||
struct zink_resource *res = zink_resource(pres);
|
||||
if (!res->obj->is_buffer && usage & PIPE_MAP_UNSYNCHRONIZED) {
|
||||
if (zink_is_swapchain(res))
|
||||
return true;
|
||||
if (!(res->obj->vkusage & VK_IMAGE_USAGE_HOST_TRANSFER_BIT_EXT) &&
|
||||
(!res->linear || !res->obj->host_visible))
|
||||
return true;
|
||||
}
|
||||
uint32_t check_usage = 0;
|
||||
if (usage & PIPE_MAP_UNSYNCHRONIZED && (!res->obj->unsync_access || zink_is_swapchain(res)))
|
||||
return true;
|
||||
if (usage & PIPE_MAP_READ)
|
||||
check_usage |= ZINK_RESOURCE_ACCESS_WRITE;
|
||||
if (usage & PIPE_MAP_WRITE)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue