rsx: Texture cache fixes

- Update section flags when requested
- Fix nullptr dereference: cached_dest will be null if dst_is_render_target is true
This commit is contained in:
kd-11 2017-09-21 21:00:42 +03:00
parent 8e66e719fa
commit 4d83d749a0
2 changed files with 13 additions and 6 deletions

View File

@ -1121,14 +1121,19 @@ namespace rsx
{
if (dest_texture)
{
if (dst_is_render_target && !dst_subres.is_depth_surface)
if (dst_is_render_target)
{
LOG_ERROR(RSX, "Depth->RGBA blit requested but not supported");
return true;
if (!dst_subres.is_depth_surface)
{
LOG_ERROR(RSX, "Depth->RGBA blit requested but not supported");
return true;
}
}
else
{
if (!cached_dest->has_compatible_format(src_subres.surface))
format_mismatch = true;
}
if (!cached_dest->has_compatible_format(src_subres.surface))
format_mismatch = true;
}
is_depth_blit = true;

View File

@ -572,6 +572,8 @@ namespace vk
view.reset(new_view);
}
section.set_view_flags(expected_flags);
}
void insert_texture_barrier() override