Vulkan allows these things that we currently don't provide:
For implementation requirements, are you thinking:
For 1), add fn destroy(&self) -> (); to hal::window::Swapchain trait and actually implement that functionality for all backends?
For 2), make hal::window::SwapchainConfig also accept an optional Swapchain and then modify existing #create_swapchain() implementations to return SwapchainConfig's Swapchain if it exists?
destroy_swapchain() to the device traitcreate_swapchain, less reference/lifetime hassle inside the SwapchainConfig struct imo.Do you want the actual implementations of destroy_swapchain() and optional swapchain creation from old swapchain in create_swapchain() to be a part of this issue or should it be separate issues for each backend?
@hriundel it's not a super huge thing, so I believe we can track it all here.
out of curiosity may I know if this task is somehow related to bug #1780 ?
It should be possible to close this issue as well due to resizing support in #2052 being merged. 馃憤 馃帀
Most helpful comment
destroy_swapchain()to the device traitcreate_swapchain, less reference/lifetime hassle inside theSwapchainConfigstruct imo.