mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2024-11-21 16:46:41 -08:00
vkd3d: Use the resource's stored format in init_default_texture_view_desc().
Signed-off-by: Conor McCarthy <cmccarthy@codeweavers.com> Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
beb9151e5d
commit
de87352f77
@ -2439,7 +2439,11 @@ static bool init_default_texture_view_desc(struct vkd3d_texture_view_desc *desc,
|
||||
{
|
||||
const struct d3d12_device *device = resource->device;
|
||||
|
||||
if (!(desc->format = vkd3d_format_from_d3d12_resource_desc(device, &resource->desc, view_format)))
|
||||
if (view_format == resource->desc.Format)
|
||||
{
|
||||
desc->format = resource->format;
|
||||
}
|
||||
else if (!(desc->format = vkd3d_format_from_d3d12_resource_desc(device, &resource->desc, view_format)))
|
||||
{
|
||||
FIXME("Failed to find format (resource format %#x, view format %#x).\n",
|
||||
resource->desc.Format, view_format);
|
||||
|
Loading…
Reference in New Issue
Block a user