diff --git a/Cargo.toml b/Cargo.toml index 445bb770da..cc2516ad98 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -26,17 +26,20 @@ vulkan = ["wgn/vulkan-portability"] [dependencies.wgn] package = "wgpu-native" version = "0.5" -#git = "https://github.com/gfx-rs/wgpu" +git = "https://github.com/gfx-rs/wgpu" +rev = "49dbe08f37f8396cff0d6672667a48116ec487f5" [dependencies.wgc] package = "wgpu-core" version = "0.5" -#git = "https://github.com/gfx-rs/wgpu" +git = "https://github.com/gfx-rs/wgpu" +rev = "49dbe08f37f8396cff0d6672667a48116ec487f5" [dependencies.wgt] package = "wgpu-types" version = "0.5" -#git = "https://github.com/gfx-rs/wgpu" +git = "https://github.com/gfx-rs/wgpu" +rev = "49dbe08f37f8396cff0d6672667a48116ec487f5" [dependencies] arrayvec = "0.5" diff --git a/examples/capture/main.rs b/examples/capture/main.rs index a6e5223908..a4fefe1feb 100644 --- a/examples/capture/main.rs +++ b/examples/capture/main.rs @@ -43,7 +43,6 @@ async fn run() { // The render pipeline renders data into this texture let texture = device.create_texture(&wgpu::TextureDescriptor { size: texture_extent, - array_layer_count: 1, mip_level_count: 1, sample_count: 1, dimension: wgpu::TextureDimension::D2, diff --git a/examples/cube/main.rs b/examples/cube/main.rs index c28760d6fd..8c111166e8 100644 --- a/examples/cube/main.rs +++ b/examples/cube/main.rs @@ -167,7 +167,6 @@ impl framework::Example for Example { }; let texture = device.create_texture(&wgpu::TextureDescriptor { size: texture_extent, - array_layer_count: 1, mip_level_count: 1, sample_count: 1, dimension: wgpu::TextureDimension::D2, diff --git a/examples/mipmap/main.rs b/examples/mipmap/main.rs index 65691c9cbe..3ba22d475c 100644 --- a/examples/mipmap/main.rs +++ b/examples/mipmap/main.rs @@ -258,7 +258,6 @@ impl framework::Example for Example { }; let texture = device.create_texture(&wgpu::TextureDescriptor { size: texture_extent, - array_layer_count: 1, mip_level_count, sample_count: 1, dimension: wgpu::TextureDimension::D2, diff --git a/examples/msaa-line/main.rs b/examples/msaa-line/main.rs index c3e1118ece..21b8518e97 100644 --- a/examples/msaa-line/main.rs +++ b/examples/msaa-line/main.rs @@ -95,7 +95,6 @@ impl Example { }; let multisampled_frame_descriptor = &wgpu::TextureDescriptor { size: multisampled_texture_extent, - array_layer_count: 1, mip_level_count: 1, sample_count: sample_count, dimension: wgpu::TextureDimension::D2, diff --git a/examples/shadow/main.rs b/examples/shadow/main.rs index 530538a050..60c656a559 100644 --- a/examples/shadow/main.rs +++ b/examples/shadow/main.rs @@ -176,7 +176,7 @@ impl Example { const SHADOW_SIZE: wgpu::Extent3d = wgpu::Extent3d { width: 512, height: 512, - depth: 1, + depth: Self::MAX_LIGHTS as u32, }; const DEPTH_FORMAT: wgpu::TextureFormat = wgpu::TextureFormat::Depth32Float; @@ -341,7 +341,6 @@ impl framework::Example for Example { let shadow_texture = device.create_texture(&wgpu::TextureDescriptor { size: Self::SHADOW_SIZE, - array_layer_count: Self::MAX_LIGHTS as u32, mip_level_count: 1, sample_count: 1, dimension: wgpu::TextureDimension::D2, @@ -635,7 +634,6 @@ impl framework::Example for Example { height: sc_desc.height, depth: 1, }, - array_layer_count: 1, mip_level_count: 1, sample_count: 1, dimension: wgpu::TextureDimension::D2, @@ -683,7 +681,6 @@ impl framework::Example for Example { height: sc_desc.height, depth: 1, }, - array_layer_count: 1, mip_level_count: 1, sample_count: 1, dimension: wgpu::TextureDimension::D2, diff --git a/examples/skybox/main.rs b/examples/skybox/main.rs index af10d79c2d..64639e1c99 100644 --- a/examples/skybox/main.rs +++ b/examples/skybox/main.rs @@ -180,15 +180,12 @@ impl framework::Example for Skybox { }) .collect::>(); - let texture_extent = wgpu::Extent3d { - width: image_width, - height: image_height, - depth: 1, - }; - let texture = device.create_texture(&wgpu::TextureDescriptor { - size: texture_extent, - array_layer_count: 6, + size: wgpu::Extent3d { + width: image_width, + height: image_height, + depth: 6, + }, mip_level_count: 1, sample_count: 1, dimension: wgpu::TextureDimension::D2, @@ -219,7 +216,11 @@ impl framework::Example for Skybox { array_layer: i as u32, origin: wgpu::Origin3d::ZERO, }, - texture_extent, + wgpu::Extent3d { + width: image_width, + height: image_height, + depth: 1, + }, ); } diff --git a/src/lib.rs b/src/lib.rs index 0bd26fd2a2..380be31b68 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -442,9 +442,6 @@ pub struct TextureDescriptor<'a> { /// The size of the texture. pub size: Extent3d, - /// The array layer count. - pub array_layer_count: u32, - /// The mip level count. pub mip_level_count: u32, @@ -942,7 +939,6 @@ impl Device { &wgt::TextureDescriptor { label: owned_label.as_ptr(), size: desc.size, - array_layer_count: desc.array_layer_count, mip_level_count: desc.mip_level_count, sample_count: desc.sample_count, dimension: desc.dimension,