pub enum RawWindowHandle {
AppKit {
ns_window: usize,
ns_view: usize,
metal_layer: usize,
},
UiKit {
ui_window: usize,
ui_view: usize,
metal_layer: usize,
is_ipad: bool,
},
Win32 {
hwnd: usize,
hinstance: usize,
},
Xlib {
window: u64,
display: usize,
},
Wayland {
surface: usize,
display: usize,
},
AndroidNdk {
native_window: usize,
},
WebCanvas {
canvas_id: u32,
},
Headless,
}Expand description
Zero-dependency ABI-stable native OS window handle for GPU surface creation.
Variants§
AppKit
macOS AppKit handle carrying (ns_window, ns_view, ca_metal_layer) pointers.
Fields
UiKit
iOS / iPadOS UIKit handle carrying (ui_window, ui_view, ca_metal_layer, is_ipad).
Fields
Win32
Windows Win32 handle carrying (hwnd, hinstance).
Xlib
Linux X11 Xlib handle carrying (window, display).
Wayland
Linux Wayland handle carrying (wl_surface, wl_display).
AndroidNdk
Android NDK handle carrying ANativeWindow*.
WebCanvas
Web browser canvas element identifier.
Headless
Offscreen headless surface with no OS window handle.
Trait Implementations§
Source§impl Clone for RawWindowHandle
impl Clone for RawWindowHandle
impl Copy for RawWindowHandle
Source§impl Debug for RawWindowHandle
impl Debug for RawWindowHandle
Source§impl Default for RawWindowHandle
impl Default for RawWindowHandle
impl Eq for RawWindowHandle
Source§impl Hash for RawWindowHandle
impl Hash for RawWindowHandle
Source§impl PartialEq for RawWindowHandle
impl PartialEq for RawWindowHandle
impl StructuralPartialEq for RawWindowHandle
Auto Trait Implementations§
impl Forget for RawWindowHandle
impl Freeze for RawWindowHandle
impl Move for RawWindowHandle
impl RefUnwindSafe for RawWindowHandle
impl Send for RawWindowHandle
impl Sync for RawWindowHandle
impl Unpin for RawWindowHandle
impl UnsafeUnpin for RawWindowHandle
impl UnwindSafe for RawWindowHandle
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more