mirror of
https://gitlab.com/veloren/veloren.git
synced 2024-08-30 18:12:32 +00:00
Replace default wgpu error handler with one that includes the error in the panic message
This commit is contained in:
parent
5b3dbca297
commit
e4fc93035b
@ -210,6 +210,16 @@ impl Renderer {
|
||||
),
|
||||
)?;
|
||||
|
||||
// Set error handler for wgpu errors
|
||||
// This is better for use than their default because it includes the error in
|
||||
// the panic message
|
||||
device.on_uncaptured_error(|error| {
|
||||
panic!(
|
||||
"wgpu error (handling all wgpu errors as fatal): {:?}",
|
||||
error
|
||||
)
|
||||
});
|
||||
|
||||
let profiler_features_enabled = device
|
||||
.features()
|
||||
.contains(wgpu_profiler::GpuProfiler::REQUIRED_WGPU_FEATURES);
|
||||
|
Loading…
Reference in New Issue
Block a user