Skip to main content

01_get_device/
01_get_device.rs

1use apple_metal::MetalDevice;
2
3fn main() {
4    let device = MetalDevice::system_default().expect("no Metal device found");
5    println!("got Metal device at {:p}", device.as_ptr());
6    assert!(!device.as_ptr().is_null());
7}