Skip to content

Commit

Permalink
Merge branch 'shadps4-emu:main' into PartBB
Browse files Browse the repository at this point in the history
  • Loading branch information
diegolix29 authored Dec 23, 2024
2 parents efaa5bc + c2e9c87 commit 2159373
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/video_core/renderer_vulkan/vk_rasterizer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,7 @@ void Rasterizer::EliminateFastClear() {
const auto& hint = liverpool->last_cb_extent[0];
VideoCore::TextureCache::RenderTargetDesc desc(col_buf, hint);
const auto& image_view = texture_cache.FindRenderTarget(desc);
const auto& image = texture_cache.GetImage(image_view.image_id);
auto& image = texture_cache.GetImage(image_view.image_id);
const vk::ImageSubresourceRange range = {
.aspectMask = vk::ImageAspectFlagBits::eColor,
.baseMipLevel = 0,
Expand All @@ -225,7 +225,8 @@ void Rasterizer::EliminateFastClear() {
.layerCount = col_buf.view.slice_max - col_buf.view.slice_start + 1,
};
scheduler.EndRendering();
scheduler.CommandBuffer().clearColorImage(image.image, vk::ImageLayout::eColorAttachmentOptimal,
image.Transit(vk::ImageLayout::eTransferDstOptimal, vk::AccessFlagBits2::eTransferWrite, {});
scheduler.CommandBuffer().clearColorImage(image.image, image.last_state.layout,
LiverpoolToVK::ColorBufferClearValue(col_buf).color,
range);
}
Expand Down

0 comments on commit 2159373

Please sign in to comment.