Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.
Prev Previous commit
++
  • Loading branch information
jonahwilliams committed Mar 7, 2024
commit 2dd355a60e5690f73b707ed6d266f1bba2ed0dab
5 changes: 3 additions & 2 deletions impeller/renderer/backend/vulkan/test/swapchain_unittests.cc
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does the test directly verify the "primary trick" outlined in the change context (recycling a single MSAA and Depth/Stencil attachment)?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It does now

Original file line number Diff line number Diff line change
Expand Up @@ -81,8 +81,9 @@ TEST(SwapchainTest, CachesRenderPassOnSwapchainImage) {
auto render_pass = command_buffer->CreateRenderPass(render_target);
render_pass->EncodeCommands();

depth_stencil_textures.push_back(
render_target.GetDepthAttachment()->texture);
auto& depth = render_target.GetDepthAttachment();
depth_stencil_textures.push_back(depth.has_value() ? depth->texture
: nullptr);
msaa_textures.push_back(
render_target.GetColorAttachments().find(0u)->second.texture);
}
Expand Down