Skip to content

Commit

Permalink
Added swapchain clone.
Browse files Browse the repository at this point in the history
  • Loading branch information
entropylost committed Mar 26, 2024
1 parent 6d494b3 commit ddfc881
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions luisa_compute/src/runtime.rs
Original file line number Diff line number Diff line change
Expand Up @@ -340,9 +340,7 @@ impl Device {
raw_window_handle::RawWindowHandle::Orbital(_) => todo!(),
raw_window_handle::RawWindowHandle::Xlib(h) => h.window as u64,
raw_window_handle::RawWindowHandle::Xcb(h) => h.window.get() as u64,
raw_window_handle::RawWindowHandle::Wayland(h) => {
h.surface.as_ptr() as u64
}
raw_window_handle::RawWindowHandle::Wayland(h) => h.surface.as_ptr() as u64,
raw_window_handle::RawWindowHandle::Drm(_) => todo!(),
raw_window_handle::RawWindowHandle::Gbm(_) => todo!(),
raw_window_handle::RawWindowHandle::Win32(h) => h.hwnd.get() as u64,
Expand Down Expand Up @@ -832,6 +830,7 @@ impl Drop for SwapchainHandle {
}
}

#[derive(Clone)]
pub struct Swapchain {
pub(crate) handle: Arc<SwapchainHandle>,
#[allow(dead_code)]
Expand Down

0 comments on commit ddfc881

Please sign in to comment.