diff options
| author | Luca Casonato <lucacasonato@yahoo.com> | 2021-05-06 16:48:45 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-05-06 16:48:45 +0200 |
| commit | f208e6a26f3c21c25dbfcfe29491a6f5660c999d (patch) | |
| tree | 65dbbd45b2f36faab8ae585eb0d270356bcba33e /extensions/webgpu/texture.rs | |
| parent | ce76f8c3a97529c86d49c39c6d9a250f978b5430 (diff) | |
chore: update wgpu and realign to spec (#9760)
Diffstat (limited to 'extensions/webgpu/texture.rs')
| -rw-r--r-- | extensions/webgpu/texture.rs | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/extensions/webgpu/texture.rs b/extensions/webgpu/texture.rs index cad4585a6..720c17be0 100644 --- a/extensions/webgpu/texture.rs +++ b/extensions/webgpu/texture.rs @@ -126,7 +126,7 @@ pub fn serialize_dimension( pub struct GpuExtent3D { pub width: Option<u32>, pub height: Option<u32>, - pub depth: Option<u32>, + pub depth_or_array_layers: Option<u32>, } #[derive(Deserialize)] @@ -159,7 +159,7 @@ pub fn op_webgpu_create_texture( size: wgpu_types::Extent3d { width: args.size.width.unwrap_or(1), height: args.size.height.unwrap_or(1), - depth: args.size.depth.unwrap_or(1), + depth_or_array_layers: args.size.depth_or_array_layers.unwrap_or(1), }, mip_level_count: args.mip_level_count.unwrap_or(1), sample_count: args.sample_count.unwrap_or(1), @@ -226,7 +226,9 @@ pub fn op_webgpu_create_texture_view( None => wgpu_types::TextureAspect::All, }, base_mip_level: args.base_mip_level.unwrap_or(0), - level_count: std::num::NonZeroU32::new(args.mip_level_count.unwrap_or(0)), + mip_level_count: std::num::NonZeroU32::new( + args.mip_level_count.unwrap_or(0), + ), base_array_layer: args.base_array_layer.unwrap_or(0), array_layer_count: std::num::NonZeroU32::new( args.array_layer_count.unwrap_or(0), |
