mirror of
https://github.com/libretro/RetroArch
synced 2025-04-25 00:02:31 +00:00
Vulkan: Don't query layout if we have optimal tiling.
This commit is contained in:
parent
0cb2bbd420
commit
f5bddd45e8
@ -441,7 +441,11 @@ struct vk_texture vulkan_create_texture(vk_t *vk,
|
|||||||
else
|
else
|
||||||
tex.view = VK_NULL_HANDLE;
|
tex.view = VK_NULL_HANDLE;
|
||||||
|
|
||||||
|
if (info.tiling == VK_IMAGE_TILING_LINEAR)
|
||||||
vkGetImageSubresourceLayout(device, tex.image, &subresource, &layout);
|
vkGetImageSubresourceLayout(device, tex.image, &subresource, &layout);
|
||||||
|
else
|
||||||
|
memset(&layout, 0, sizeof(layout));
|
||||||
|
|
||||||
tex.stride = layout.rowPitch;
|
tex.stride = layout.rowPitch;
|
||||||
tex.offset = layout.offset;
|
tex.offset = layout.offset;
|
||||||
tex.size = layout.size;
|
tex.size = layout.size;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user