zink: flag swapchain resources as swapchains
Reviewed-by: Adam Jackson <ajax@redhat.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16038>
This commit is contained in:
committed by
Marge Bot
parent
625457caaf
commit
4af98df955
@@ -977,6 +977,7 @@ resource_create(struct pipe_screen *pscreen,
|
||||
res->obj->vkusage = cdt->swapchain->scci.imageUsage;
|
||||
res->base.b.bind |= PIPE_BIND_DISPLAY_TARGET;
|
||||
res->optimal_tiling = true;
|
||||
res->swapchain = true;
|
||||
}
|
||||
if (res->obj->is_buffer) {
|
||||
res->base.buffer_id_unique = util_idalloc_mt_alloc(&screen->buffer_ids);
|
||||
|
||||
@@ -152,6 +152,7 @@ struct zink_resource {
|
||||
};
|
||||
};
|
||||
|
||||
bool swapchain;
|
||||
bool dmabuf_acquire;
|
||||
unsigned dt_stride;
|
||||
|
||||
@@ -218,7 +219,7 @@ zink_resource_has_binds(const struct zink_resource *res)
|
||||
static inline bool
|
||||
zink_is_swapchain(const struct zink_resource *res)
|
||||
{
|
||||
return (res->base.b.bind & PIPE_BIND_DISPLAY_TARGET) > 0;
|
||||
return res->swapchain;
|
||||
}
|
||||
|
||||
#ifndef __cplusplus
|
||||
|
||||
Reference in New Issue
Block a user