You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
GFX version: 0.5.0, with dx12 backend version 0.5.0
OS: Windows 10
GPU: Nvidia Quadro M1200
Here is the cleanup code I am using, for context. The unconfigure_swapchain line towards the end causes the crash. I can have either the destroy_surface, or the unconfigure, but not both.
impl Drop for Renderer {
fn drop(&mut self) {
let device = self.device.borrow();
unsafe {
device.destroy_render_pass(self.render_pass.take().unwrap());
device.destroy_buffer(self.uniform_buffer.take().unwrap());
device.free_memory(self.uniform_buffer_memory.take().unwrap());
for semaphore in self.frame_semaphores.take().unwrap() {
device.destroy_semaphore(semaphore);
}
for fence in self.frame_fences.take().unwrap() {
device.destroy_fence(fence);
}
// The following line crashes:
self.surface.as_mut().unwrap().unconfigure_swapchain(&device);
self.instance.destroy_surface(self.surface.take().unwrap());
device.wait_idle().unwrap();
for mut command_pool in self.command_pools.take().unwrap() {
command_pool.reset(true);
device.destroy_command_pool(command_pool);
}
}
}
}
There's no HRESULT or panic message to share, the window just stops responding, then when I close it, the terminal logs error code 255.
The text was updated successfully, but these errors were encountered:
637: Wait for idle before destroying swapchains r=kvark a=kvark
Follow up to #636
I was trying to address the D3D12 error in gfx-rs/gfx#3242
The debug messages complain about a resource being used by the queue while it's being destroyed. I thought forcing a wait there would help, but it does not. I think it's still a good change to land though.
In the meantime, I wonder if it considers the swapchain to be used because it's currently presented. Could be something else I'm missing here.
Co-authored-by: Dzmitry Malyshau <dmalyshau@mozilla.com>
Here is the cleanup code I am using, for context. The
unconfigure_swapchain
line towards the end causes the crash. I can have either thedestroy_surface
, or the unconfigure, but not both.There's no HRESULT or panic message to share, the window just stops responding, then when I close it, the terminal logs error code 255.
The text was updated successfully, but these errors were encountered: