From f4e6f04da137bfc72aef8b6817a57f1d9c804d0e Mon Sep 17 00:00:00 2001 From: David Huculak Date: Thu, 30 Jun 2022 21:00:42 -0400 Subject: [PATCH 1/2] add other breaking changes to 0.13 changelog --- CHANGELOG.md | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 92c9e3fdee..a6c743f17b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -119,6 +119,52 @@ is an under-documented area that we hope to improve in the future. Calling `queue.submit` now returns an opaque submission index that can be used as an argument to `device.poll` to say which submission to wait to complete. +### Other Breaking Changes + +`Device::create_shader_module` now takes the shader descriptor by value: + +```diff +- device.create_shader_module(&shader_module_descriptor) ++ device.create_shader_module(shader_module_descriptor) +``` + +Color attachments can be sparse, so they are now optional: + +```diff +FragmentState { +- targets: &[color_target_state] ++ targets: &[Some(color_target_state)] + // .. +} +``` + +```diff +RenderPassDescriptor { +- color_attachments: &[render_pass_color_attachment] ++ color_attachments: &[Some(render_pass_color_attachment)] + // .. +} +``` + +```diff +RenderBundleEncoderDescriptor { +- color_formats: &[texture_format] ++ color_formats: &[Some(texture_format)] + // .. +} +``` + +`Extent3d::max_mips` now requires you to pass a TextureDimension to specify whether or not depth_or_array_layers should be ignored: + +```diff +Extent3d { + width: 1920, + height: 1080, + depth_or_array_layers: 6, +- }.max_mips() ++ }.max_mips(wgpu::TextureDimension::D3) +``` + ### Added/New Features #### General From 14bd23541211726559d789f9b0051eef60689b30 Mon Sep 17 00:00:00 2001 From: David Huculak Date: Thu, 30 Jun 2022 21:01:41 -0400 Subject: [PATCH 2/2] fix typo --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index a6c743f17b..dd41e06489 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -97,7 +97,7 @@ based GPUs, such as mobile devices and Apple's M chips. `Features::TIMESTAMP_QUERIES` now allows for calling `write_timestamp` only on `CommandEncoder`s. -`Features::WRITE_TIMESTAMP_INSIDE_PASSES` is needed to calling `write_timestamp` on `RenderPassEncoder`s or `ComputePassEncoder`s. +`Features::WRITE_TIMESTAMP_INSIDE_PASSES` is needed to call `write_timestamp` on `RenderPassEncoder`s or `ComputePassEncoder`s. #### map_async