From 21e9013f83d51b450e4d23137f43649765ea75ef Mon Sep 17 00:00:00 2001 From: Eero Lehtinen Date: Sun, 24 Mar 2024 02:16:32 +0200 Subject: [PATCH] Add logging for the ignored error --- crates/bevy_render/src/view/window/mod.rs | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/crates/bevy_render/src/view/window/mod.rs b/crates/bevy_render/src/view/window/mod.rs index f9806bec47e1d..97144eff21b99 100644 --- a/crates/bevy_render/src/view/window/mod.rs +++ b/crates/bevy_render/src/view/window/mod.rs @@ -319,7 +319,12 @@ pub fn prepare_windows( match surface.get_current_texture() { Ok(frame) => window.set_swapchain_texture(frame), #[cfg(target_os = "linux")] - Err(wgpu::SurfaceError::Outdated) if is_nvidia() => {} + Err(wgpu::SurfaceError::Outdated) if is_nvidia() => { + bevy_utils::tracing::debug!( + "Couldn't get swap chain texture. This often happens with \ + the Nvidia 550 driver. It can be safely ignored." + ); + } Err(err) => panic!("Error configuring surface: {err}"), }; } else { @@ -328,7 +333,12 @@ pub fn prepare_windows( window.set_swapchain_texture(frame); } #[cfg(target_os = "linux")] - Err(wgpu::SurfaceError::Outdated) if is_nvidia() => {} + Err(wgpu::SurfaceError::Outdated) if is_nvidia() => { + bevy_utils::tracing::debug!( + "Couldn't get swap chain texture. This often happens with \ + the Nvidia 550 driver. It can be safely ignored." + ); + } Err(wgpu::SurfaceError::Outdated) => { render_device.configure_surface(surface, &surface_data.configuration); let frame = surface