Merge pull request #876 from Cupnfish/master
Add a primary backend that can be set
This commit is contained in:
commit
0ce6a2db21
@ -47,6 +47,7 @@ impl Settings {
|
||||
/// - `dx11`
|
||||
/// - `gl`
|
||||
/// - `webgpu`
|
||||
/// - `primary`
|
||||
pub fn from_env() -> Self {
|
||||
Settings {
|
||||
internal_backend: backend_from_env()
|
||||
@ -78,6 +79,7 @@ fn backend_from_env() -> Option<wgpu::BackendBit> {
|
||||
"dx11" => wgpu::BackendBit::DX11,
|
||||
"gl" => wgpu::BackendBit::GL,
|
||||
"webgpu" => wgpu::BackendBit::BROWSER_WEBGPU,
|
||||
"primary" => wgpu::BackendBit::PRIMARY,
|
||||
other => panic!("Unknown backend: {}", other),
|
||||
}
|
||||
})
|
||||
|
Loading…
Reference in New Issue
Block a user