| 99 | } |
| 100 | |
| 101 | void AFBCSample::recreate_swapchain() |
| 102 | { |
| 103 | std::set<VkImageUsageFlagBits> image_usage_flags = {VK_IMAGE_USAGE_COLOR_ATTACHMENT_BIT}; |
| 104 | |
| 105 | if (!afbc_enabled) |
| 106 | { |
| 107 | // To force-disable AFBC, set an invalid image usage flag |
| 108 | image_usage_flags.insert(VK_IMAGE_USAGE_STORAGE_BIT); |
| 109 | } |
| 110 | |
| 111 | get_device().wait_idle(); |
| 112 | |
| 113 | get_render_context().update_swapchain(image_usage_flags); |
| 114 | } |
| 115 | |
| 116 | void AFBCSample::draw_gui() |
| 117 | { |
nothing calls this directly
no test coverage detected