Upgrade to wgpu 24 (#127)
This commit is contained in:
parent
7264e5f324
commit
bff018f6af
7 changed files with 23 additions and 15 deletions
|
@ -1,3 +1,5 @@
|
|||
use wgpu::{BackendOptions, Dx12BackendOptions};
|
||||
|
||||
use pollster::block_on;
|
||||
|
||||
pub struct State {
|
||||
|
@ -7,11 +9,17 @@ pub struct State {
|
|||
|
||||
impl State {
|
||||
pub fn new() -> Self {
|
||||
let instance = wgpu::Instance::new(wgpu::InstanceDescriptor {
|
||||
let instance = wgpu::Instance::new(&wgpu::InstanceDescriptor {
|
||||
backends: wgpu::Backends::all(),
|
||||
flags: wgpu::InstanceFlags::empty(),
|
||||
dx12_shader_compiler: wgpu::Dx12Compiler::Fxc,
|
||||
gles_minor_version: wgpu::Gles3MinorVersion::Automatic,
|
||||
backend_options: BackendOptions {
|
||||
gl: wgpu::GlBackendOptions {
|
||||
gles_minor_version: wgpu::Gles3MinorVersion::Automatic
|
||||
},
|
||||
dx12: Dx12BackendOptions {
|
||||
shader_compiler: wgpu::Dx12Compiler::Fxc
|
||||
},
|
||||
}
|
||||
});
|
||||
|
||||
let adapter = block_on(wgpu::util::initialize_adapter_from_env_or_default(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue