From e7f01eff80aadfdb773b1c59ad77e552a84f21a0 Mon Sep 17 00:00:00 2001 From: Quaternions Date: Tue, 13 Feb 2024 05:55:11 -0800 Subject: [PATCH] print instead of panic --- src/graphics.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/graphics.rs b/src/graphics.rs index be53af1..55b2a38 100644 --- a/src/graphics.rs +++ b/src/graphics.rs @@ -162,7 +162,10 @@ impl GraphicsState{ height=height/4*4; wgpu::TextureFormat::Bc7RgbaUnormSrgb }, - other=>panic!("unsupported format{:?}",other), + other=>{ + println!("unsupported texture format{:?}",other); + return None; + }, }; let size=wgpu::Extent3d{