Mend Renovate
This PR contains the following updates:
| Package |
Type |
Update |
Change |
| wgpu (source) |
dependencies |
minor |
0.15 -> 0.16 |
Release Notes
gfx-rs/wgpu
Compare Source
Major changes
Shader Changes
type has been replaced with alias to match with upstream WebGPU.
- type MyType = vec4<u32>;
+ alias MyType = vec4<u32>;
TextureFormat info API
The TextureFormat::describe function was removed in favor of separate functions: block_dimensions, is_compressed, is_srgb, required_features, guaranteed_format_features, sample_type and block_size.
- let block_dimensions = format.describe().block_dimensions;
+ let block_dimensions = format.block_dimensions();
- let is_compressed = format.describe().is_compressed();
+ let is_compressed = format.is_compressed();
- let is_srgb = format.describe().srgb;
+ let is_srgb = format.is_srgb();
- let required_features = format.describe().required_features;
+ let required_features = format.required_features();
Additionally guaranteed_format_features now takes a set of features to assume are enabled.
- let guaranteed_format_features = format.describe().guaranteed_format_features;
+ let guaranteed_format_features = format.guaranteed_format_features(device.features());
Additionally sample_type and block_size now take an optional TextureAspect and return Options.
- let sample_type = format.describe().sample_type;
+ let sample_type = format.sample_type(None).expect("combined depth-stencil format requires specifying a TextureAspect");
- let block_size = format.describe().block_size;
+ let block_size = format.block_size(None).expect("combined depth-stencil format requires specifying a TextureAspect");
By @teoxoy in #3436
BufferUsages::QUERY_RESOLVE
Buffers used as the destination argument of CommandEncoder::resolve_query_set now have to contain the QUERY_RESOLVE usage instead of the COPY_DST usage.
let destination = device.create_buffer(&wgpu::BufferDescriptor {
// ...
- usage: wgpu::BufferUsages::COPY_DST | wgpu::BufferUsages::MAP_READ,
+ usage: wgpu::BufferUsages::QUERY_RESOLVE | wgpu::BufferUsages::MAP_READ,
mapped_at_creation: false,
});
command_encoder.resolve_query_set(&query_set, query_range, &destination, destination_offset);
By @JolifantoBambla in #3489
Renamed features
The following Features have been renamed.
SHADER_FLOAT16 -> SHADER_F16
SHADER_FLOAT64 -> SHADER_F64
SHADER_INT16 -> SHADER_I16
TEXTURE_COMPRESSION_ASTC_LDR -> TEXTURE_COMPRESSION_ASTC
WRITE_TIMESTAMP_INSIDE_PASSES -> TIMESTAMP_QUERY_INSIDE_PASSES
By @teoxoy in #3534
Anisotropic Filtering
Anisotropic filtering has been brought in line with the spec. The anisotropic clamp is now a u16 (was a Option<u8>) which must be at least 1.
If the anisotropy clamp is not 1, all the filters in a sampler must be Linear.
SamplerDescriptor {
- anisotropic_clamp: None,
+ anisotropic_clamp: 1,
}
By @cwfitzgerald in #3610.
TextureFormat Names
Some texture format names have changed to get back in line with the spec.
- TextureFormat::Bc6hRgbSfloat
+ TextureFormat::Bc6hRgbFloat
By @cwfitzgerald in #3671.
Misc Breaking Changes
- Change type of
mip_level_count and array_layer_count (members of TextureViewDescriptor and ImageSubresourceRange) from Option<NonZeroU32> to Option<u32>. By @teoxoy in #3445
- Change type of
bytes_per_row and rows_per_image (members of ImageDataLayout) from Option<NonZeroU32> to Option<u32>. By @teoxoy in #3529
- On Web,
Instance::create_surface_from_canvas() and create_surface_from_offscreen_canvas() now take the canvas by value. By @daxpedda in #3690
Changes
General
- Added
TextureFormatFeatureFlags::MULTISAMPLE_X16. By @Dinnerbone in #3454
- Added
BufferUsages::QUERY_RESOLVE. By @JolifantoBambla in #3489
- Support stencil-only views and copying to/from combined depth-stencil textures. By @teoxoy in #3436
- Added
Features::SHADER_EARLY_DEPTH_TEST. By @teoxoy in #3494
- All
fxhash dependencies have been replaced with rustc-hash. By @james7132 in #3502
- Allow copying of textures with copy-compatible formats. By @teoxoy in #3528
- Improve attachment related errors. By @cwfitzgerald in #3549
- Make error descriptions all upper case. By @cwfitzgerald in #3549
- Don't include ANSI terminal color escape sequences in shader module validation error messages. By @jimblandy in #3591
- Report error messages from DXC compile. By @Davidster in #3632
- Error in native when using a filterable
TextureSampleType::Float on a multisample BindingType::Texture. By @mockersf in #3686
- On Web, the size of the canvas is adjusted when using
Surface::configure(). If the canvas was given an explicit size (via CSS), this will not affect the visual size of the canvas. By @daxpedda in #3690
WebGPU
Vulkan
- Set
max_memory_allocation_size via PhysicalDeviceMaintenance3Properties. By @jinleili in #3567
- Silence false-positive validation error about surface resizing. By @seabassjh in #3627
Bug Fixes
General
copyTextureToTexture src/dst aspects must both refer to all aspects of src/dst format. By @teoxoy in #3431
- Validate before extracting texture selectors. By @teoxoy in #3487
- Fix fatal errors (those which panic even if an error handler is set) not including all of the details. By @kpreid in #3563
- Validate shader location clashes. By @emilk in #3613
- Fix surfaces not being dropped until exit. By @benjaminschaaf in #3647
WebGPU
- Fix handling of
None values for depth_ops and stencil_ops in RenderPassDescriptor::depth_stencil_attachment. By @niklaskorz in #3660
- Avoid using
WasmAbi functions for WebGPU backend. By @grovesNL in #3657
DX12
- Use typeless formats for textures that might be viewed as srgb or non-srgb. By @teoxoy in #3555
GLES
- Set FORCE_POINT_SIZE if it is vertex shader with mesh consist of point list. By @REASY in 3440
- Remove unwraps inside
surface.configure. By @cwfitzgerald in #3585
- Fix
copy_external_image_to_texture, copy_texture_to_texture and copy_buffer_to_texture not taking the specified index into account if the target texture is a cube map, 2D texture array or cube map array. By @daxpedda #3641
- Fix disabling of vertex attributes with non-consecutive locations. By @Azorlogh in #3706
Metal
Vulkan
Examples
- Use
BufferUsages::QUERY_RESOLVE instead of BufferUsages::COPY_DST for buffers used in CommandEncoder::resolve_query_set calls in mipmap example. By @JolifantoBambla in #3489
Compare Source
Changes
General
- Fix for some minor issues in comments on some features. By @Wumpf in #3455
Vulkan
DX12
WebGPU
Bug Fixes
General
Vulkan
DX12
GLES
WebGPU
Documentation
General
Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR has been generated by Mend Renovate. View repository job log here.
[](https://renovatebot.com)
This PR contains the following updates:
| Package | Type | Update | Change |
|---|---|---|---|
| [wgpu](https://wgpu.rs/) ([source](https://togithub.com/gfx-rs/wgpu)) | dependencies | minor | `0.15` -> `0.16` |
---
### Release Notes
<details>
<summary>gfx-rs/wgpu</summary>
### [`v0.16.0`](https://togithub.com/gfx-rs/wgpu/blob/HEAD/CHANGELOG.md#v0160-2023年04月19日)
[Compare Source](https://togithub.com/gfx-rs/wgpu/compare/v0.15.1...v0.16.0)
##### Major changes
##### Shader Changes
`type` has been replaced with `alias` to match with upstream WebGPU.
```diff
- type MyType = vec4<u32>;
+ alias MyType = vec4<u32>;
```
##### TextureFormat info API
The `TextureFormat::describe` function was removed in favor of separate functions: `block_dimensions`, `is_compressed`, `is_srgb`, `required_features`, `guaranteed_format_features`, `sample_type` and `block_size`.
```diff
- let block_dimensions = format.describe().block_dimensions;
+ let block_dimensions = format.block_dimensions();
- let is_compressed = format.describe().is_compressed();
+ let is_compressed = format.is_compressed();
- let is_srgb = format.describe().srgb;
+ let is_srgb = format.is_srgb();
- let required_features = format.describe().required_features;
+ let required_features = format.required_features();
```
Additionally `guaranteed_format_features` now takes a set of features to assume are enabled.
```diff
- let guaranteed_format_features = format.describe().guaranteed_format_features;
+ let guaranteed_format_features = format.guaranteed_format_features(device.features());
```
Additionally `sample_type` and `block_size` now take an optional `TextureAspect` and return `Option`s.
```diff
- let sample_type = format.describe().sample_type;
+ let sample_type = format.sample_type(None).expect("combined depth-stencil format requires specifying a TextureAspect");
- let block_size = format.describe().block_size;
+ let block_size = format.block_size(None).expect("combined depth-stencil format requires specifying a TextureAspect");
```
By [@​teoxoy](https://togithub.com/teoxoy) in [#​3436](https://togithub.com/gfx-rs/wgpu/pull/3436)
##### BufferUsages::QUERY_RESOLVE
Buffers used as the `destination` argument of `CommandEncoder::resolve_query_set` now have to contain the `QUERY_RESOLVE` usage instead of the `COPY_DST` usage.
```diff
let destination = device.create_buffer(&wgpu::BufferDescriptor {
// ...
- usage: wgpu::BufferUsages::COPY_DST | wgpu::BufferUsages::MAP_READ,
+ usage: wgpu::BufferUsages::QUERY_RESOLVE | wgpu::BufferUsages::MAP_READ,
mapped_at_creation: false,
});
command_encoder.resolve_query_set(&query_set, query_range, &destination, destination_offset);
```
By [@​JolifantoBambla](https://togithub.com/JolifantoBambla) in [#​3489](https://togithub.com/gfx-rs/wgpu/pull/3489)
##### Renamed features
The following `Features` have been renamed.
- `SHADER_FLOAT16` -> `SHADER_F16`
- `SHADER_FLOAT64` -> `SHADER_F64`
- `SHADER_INT16` -> `SHADER_I16`
- `TEXTURE_COMPRESSION_ASTC_LDR` -> `TEXTURE_COMPRESSION_ASTC`
- `WRITE_TIMESTAMP_INSIDE_PASSES` -> `TIMESTAMP_QUERY_INSIDE_PASSES`
By [@​teoxoy](https://togithub.com/teoxoy) in [#​3534](https://togithub.com/gfx-rs/wgpu/pull/3534)
##### Anisotropic Filtering
Anisotropic filtering has been brought in line with the spec. The anisotropic clamp is now a `u16` (was a `Option<u8>`) which must be at least 1.
If the anisotropy clamp is not 1, all the filters in a sampler must be `Linear`.
```diff
SamplerDescriptor {
- anisotropic_clamp: None,
+ anisotropic_clamp: 1,
}
```
By [@​cwfitzgerald](https://togithub.com/cwfitzgerald) in [#​3610](https://togithub.com/gfx-rs/wgpu/pull/3610).
##### TextureFormat Names
Some texture format names have changed to get back in line with the spec.
```diff
- TextureFormat::Bc6hRgbSfloat
+ TextureFormat::Bc6hRgbFloat
```
By [@​cwfitzgerald](https://togithub.com/cwfitzgerald) in [#​3671](https://togithub.com/gfx-rs/wgpu/pull/3671).
##### Misc Breaking Changes
- Change type of `mip_level_count` and `array_layer_count` (members of `TextureViewDescriptor` and `ImageSubresourceRange`) from `Option<NonZeroU32>` to `Option<u32>`. By [@​teoxoy](https://togithub.com/teoxoy) in [#​3445](https://togithub.com/gfx-rs/wgpu/pull/3445)
- Change type of `bytes_per_row` and `rows_per_image` (members of `ImageDataLayout`) from `Option<NonZeroU32>` to `Option<u32>`. By [@​teoxoy](https://togithub.com/teoxoy) in [#​3529](https://togithub.com/gfx-rs/wgpu/pull/3529)
- On Web, `Instance::create_surface_from_canvas()` and `create_surface_from_offscreen_canvas()` now take the canvas by value. By [@​daxpedda](https://togithub.com/daxpedda) in [#​3690](https://togithub.com/gfx-rs/wgpu/pull/3690)
##### Changes
##### General
- Added `TextureFormatFeatureFlags::MULTISAMPLE_X16`. By [@​Dinnerbone](https://togithub.com/Dinnerbone) in [#​3454](https://togithub.com/gfx-rs/wgpu/pull/3454)
- Added `BufferUsages::QUERY_RESOLVE`. By [@​JolifantoBambla](https://togithub.com/JolifantoBambla) in [#​3489](https://togithub.com/gfx-rs/wgpu/pull/3489)
- Support stencil-only views and copying to/from combined depth-stencil textures. By [@​teoxoy](https://togithub.com/teoxoy) in [#​3436](https://togithub.com/gfx-rs/wgpu/pull/3436)
- Added `Features::SHADER_EARLY_DEPTH_TEST`. By [@​teoxoy](https://togithub.com/teoxoy) in [#​3494](https://togithub.com/gfx-rs/wgpu/pull/3494)
- All `fxhash` dependencies have been replaced with `rustc-hash`. By [@​james7132](https://togithub.com/james7132) in [#​3502](https://togithub.com/gfx-rs/wgpu/pull/3502)
- Allow copying of textures with copy-compatible formats. By [@​teoxoy](https://togithub.com/teoxoy) in [#​3528](https://togithub.com/gfx-rs/wgpu/pull/3528)
- Improve attachment related errors. By [@​cwfitzgerald](https://togithub.com/cwfitzgerald) in [#​3549](https://togithub.com/gfx-rs/wgpu/pull/3549)
- Make error descriptions all upper case. By [@​cwfitzgerald](https://togithub.com/cwfitzgerald) in [#​3549](https://togithub.com/gfx-rs/wgpu/pull/3549)
- Don't include ANSI terminal color escape sequences in shader module validation error messages. By [@​jimblandy](https://togithub.com/jimblandy) in [#​3591](https://togithub.com/gfx-rs/wgpu/pull/3591)
- Report error messages from DXC compile. By [@​Davidster](https://togithub.com/Davidster) in [#​3632](https://togithub.com/gfx-rs/wgpu/pull/3632)
- Error in native when using a filterable `TextureSampleType::Float` on a multisample `BindingType::Texture`. By [@​mockersf](https://togithub.com/mockersf) in [#​3686](https://togithub.com/gfx-rs/wgpu/pull/3686)
- On Web, the size of the canvas is adjusted when using `Surface::configure()`. If the canvas was given an explicit size (via CSS), this will not affect the visual size of the canvas. By [@​daxpedda](https://togithub.com/daxpedda) in [#​3690](https://togithub.com/gfx-rs/wgpu/pull/3690)
##### WebGPU
- Implement the new checks for readonly stencils. By [@​JCapucho](https://togithub.com/JCapucho) in [#​3443](https://togithub.com/gfx-rs/wgpu/pull/3443)
- Reimplement `adapter|device_features`. By [@​jinleili](https://togithub.com/jinleili) in [#​3428](https://togithub.com/gfx-rs/wgpu/pull/3428)
- Implement `command_encoder_resolve_query_set`. By [@​JolifantoBambla](https://togithub.com/JolifantoBambla) in [#​3489](https://togithub.com/gfx-rs/wgpu/pull/3489)
- Add support for `Features::RG11B10UFLOAT_RENDERABLE`. By [@​mockersf](https://togithub.com/mockersf) in [#​3689](https://togithub.com/gfx-rs/wgpu/pull/3689)
##### Vulkan
- Set `max_memory_allocation_size` via `PhysicalDeviceMaintenance3Properties`. By [@​jinleili](https://togithub.com/jinleili) in [#​3567](https://togithub.com/gfx-rs/wgpu/pull/3567)
- Silence false-positive validation error about surface resizing. By [@​seabassjh](https://togithub.com/seabassjh) in [#​3627](https://togithub.com/gfx-rs/wgpu/pull/3627)
##### Bug Fixes
##### General
- `copyTextureToTexture` src/dst aspects must both refer to all aspects of src/dst format. By [@​teoxoy](https://togithub.com/teoxoy) in [#​3431](https://togithub.com/gfx-rs/wgpu/pull/3431)
- Validate before extracting texture selectors. By [@​teoxoy](https://togithub.com/teoxoy) in [#​3487](https://togithub.com/gfx-rs/wgpu/pull/3487)
- Fix fatal errors (those which panic even if an error handler is set) not including all of the details. By [@​kpreid](https://togithub.com/kpreid) in [#​3563](https://togithub.com/gfx-rs/wgpu/pull/3563)
- Validate shader location clashes. By [@​emilk](https://togithub.com/emilk) in [#​3613](https://togithub.com/gfx-rs/wgpu/pull/3613)
- Fix surfaces not being dropped until exit. By [@​benjaminschaaf](https://togithub.com/benjaminschaaf) in [#​3647](https://togithub.com/gfx-rs/wgpu/pull/3647)
##### WebGPU
- Fix handling of `None` values for `depth_ops` and `stencil_ops` in `RenderPassDescriptor::depth_stencil_attachment`. By [@​niklaskorz](https://togithub.com/niklaskorz) in [#​3660](https://togithub.com/gfx-rs/wgpu/pull/3660)
- Avoid using `WasmAbi` functions for WebGPU backend. By [@​grovesNL](https://togithub.com/grovesNL) in [#​3657](https://togithub.com/gfx-rs/wgpu/pull/3657)
##### DX12
- Use typeless formats for textures that might be viewed as srgb or non-srgb. By [@​teoxoy](https://togithub.com/teoxoy) in [#​3555](https://togithub.com/gfx-rs/wgpu/pull/3555)
##### GLES
- Set FORCE_POINT_SIZE if it is vertex shader with mesh consist of point list. By [@​REASY](https://togithub.com/REASY) in [3440](https://togithub.com/gfx-rs/wgpu/pull/3440)
- Remove unwraps inside `surface.configure`. By [@​cwfitzgerald](https://togithub.com/cwfitzgerald) in [#​3585](https://togithub.com/gfx-rs/wgpu/pull/3585)
- Fix `copy_external_image_to_texture`, `copy_texture_to_texture` and `copy_buffer_to_texture` not taking the specified index into account if the target texture is a cube map, 2D texture array or cube map array. By [@​daxpedda](https://togithub.com/daxpedda) [#​3641](https://togithub.com/gfx-rs/wgpu/pull/3641)
- Fix disabling of vertex attributes with non-consecutive locations. By [@​Azorlogh](https://togithub.com/Azorlogh) in [#​3706](https://togithub.com/gfx-rs/wgpu/pull/3706)
##### Metal
- Fix metal erroring on an `array_stride` of 0. By [@​teoxoy](https://togithub.com/teoxoy) in [#​3538](https://togithub.com/gfx-rs/wgpu/pull/3538)
- `create_texture` returns an error if `new_texture` returns NULL. By [@​jinleili](https://togithub.com/jinleili) in [#​3554](https://togithub.com/gfx-rs/wgpu/pull/3554)
- Fix shader bounds checking being ignored. By [@​FL33TW00D](https://togithub.com/FL33TW00D) in [#​3603](https://togithub.com/gfx-rs/wgpu/pull/3603)
##### Vulkan
- Treat `VK_SUBOPTIMAL_KHR` as `VK_SUCCESS` on Android due to rotation issues. By [@​James2022-rgb](https://togithub.com/James2022-rgb) in [#​3525](https://togithub.com/gfx-rs/wgpu/pull/3525)
##### Examples
- Use `BufferUsages::QUERY_RESOLVE` instead of `BufferUsages::COPY_DST` for buffers used in `CommandEncoder::resolve_query_set` calls in `mipmap` example. By [@​JolifantoBambla](https://togithub.com/JolifantoBambla) in [#​3489](https://togithub.com/gfx-rs/wgpu/pull/3489)
### [`v0.15.1`](https://togithub.com/gfx-rs/wgpu/blob/HEAD/CHANGELOG.md#wgpu-0151-2023年02月09日)
[Compare Source](https://togithub.com/gfx-rs/wgpu/compare/v0.15.0...v0.15.1)
##### Changes
##### General
- Fix for some minor issues in comments on some features. By [@​Wumpf](https://togithub.com/Wumpf) in [#​3455](https://togithub.com/gfx-rs/wgpu/pull/3455)
##### Vulkan
- Improve format MSAA capabilities detection. By [@​jinleili](https://togithub.com/jinleili) in [#​3429](https://togithub.com/gfx-rs/wgpu/pull/3429)
##### DX12
- Update gpu allocator to 0.22. By [@​Elabajaba](https://togithub.com/Elabajaba) in [#​3447](https://togithub.com/gfx-rs/wgpu/pull/3447)
##### WebGPU
- Implement `CommandEncoder::clear_buffer`. By [@​raphlinus](https://togithub.com/raphlinus) in [#​3426](https://togithub.com/gfx-rs/wgpu/pull/3426)
##### Bug Fixes
##### General
- Re-sort supported surface formats based on srgb-ness. By [@​cwfitzgerald](https://togithub.com/cwfitzgerald) in [#​3444](https://togithub.com/gfx-rs/wgpu/pull/3444)
##### Vulkan
- Fix surface view formats validation error. By [@​jinleili](https://togithub.com/jinleili) in [#​3432](https://togithub.com/gfx-rs/wgpu/pull/3432)
##### DX12
- Fix DXC validation issues when using a custom `dxil_path`. By [@​Elabajaba](https://togithub.com/Elabajaba) in [#​3434](https://togithub.com/gfx-rs/wgpu/pull/3434)
##### GLES
- Unbind vertex buffers at end of renderpass. By [@​cwfitzgerald](https://togithub.com/cwfitzgerald) in [#​3459](https://togithub.com/gfx-rs/wgpu/pull/3459)
##### WebGPU
- Reimplement `{adapter|device}_features`. By [@​jinleili](https://togithub.com/jinleili) in [#​3428](https://togithub.com/gfx-rs/wgpu/pull/3428)
##### Documentation
##### General
- Build for WASM on docs.rs. By [@​daxpedda](https://togithub.com/daxpedda) in [#​3462](https://togithub.com/gfx-rs/wgpu/pull/3428)
</details>
---
### Configuration
📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.
♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 **Ignore**: Close this PR and you won't be reminded about this update again.
---
- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box
---
This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/astatide/decay).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNS40OS4wIiwidXBkYXRlZEluVmVyIjoiMzUuNTQuMCJ9-->