mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
update wgpu
This commit is contained in:
parent
6e28d7b3ec
commit
01c8b24e9f
3 changed files with 15 additions and 15 deletions
|
@ -16,6 +16,7 @@ use crate::dom::globalscope::GlobalScope;
|
|||
use crate::dom::gpudevice::{convert_texture_format, convert_texture_view_dimension, GPUDevice};
|
||||
use crate::dom::gputextureview::GPUTextureView;
|
||||
use dom_struct::dom_struct;
|
||||
use std::num::NonZeroU32;
|
||||
use std::string::String;
|
||||
use webgpu::{wgt, WebGPU, WebGPURequest, WebGPUTexture, WebGPUTextureView};
|
||||
|
||||
|
@ -152,9 +153,9 @@ impl GPUTextureMethods for GPUTexture {
|
|||
GPUTextureAspect::Depth_only => wgt::TextureAspect::DepthOnly,
|
||||
},
|
||||
base_mip_level: descriptor.baseMipLevel,
|
||||
level_count: descriptor.mipLevelCount.as_ref().copied(),
|
||||
level_count: descriptor.mipLevelCount.and_then(NonZeroU32::new),
|
||||
base_array_layer: descriptor.baseArrayLayer,
|
||||
array_layer_count: descriptor.arrayLayerCount.as_ref().copied(),
|
||||
array_layer_count: descriptor.arrayLayerCount.and_then(NonZeroU32::new),
|
||||
};
|
||||
|
||||
let texture_view_id = self
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue