Skip to content

Conversation

renovate[bot]
Copy link
Contributor

@renovate renovate bot commented Jul 14, 2025

This PR contains the following updates:

Package Type Update Change
wgpu (source) dependencies major 25.0.0 -> 26.0.0

Release Notes

gfx-rs/wgpu (wgpu)

v26.0.1

Compare Source

Bug Fixes
  • Fixed build error inside wgpu::util::initialize_adapter_from_env when std feature is not enabled. By @​kpreid in #​7918.
  • Fixed build error occurring when the profiling dependency is configured to have profiling active. By @​kpreid in #​7916.
  • Emit a validation error instead of panicking when a query set index is OOB. By @​ErichDonGubler in #​7908.

v26.0.0

Compare Source

Major Features
New method TextureView::texture

You can now call texture_view.texture() to get access to the texture that
a given texture view points to.

By @​cwfitzgerald and @​Wumpf in #​7907.

as_hal calls now return guards instead of using callbacks.

Previously, if you wanted to get access to the wgpu-hal or underlying api types, you would call as_hal and get the hal type as a callback. Now the function returns a guard which dereferences to the hal type.

- device.as_hal::<hal::api::Vulkan>(|hal_device| {...});
+ let hal_device: impl Deref<Item = hal::vulkan::Device> = device.as_hal::<hal::api::Vulkan>();

By @​cwfitzgerald in #​7863.

Enabling Vulkan Features/Extensions

For those who are doing vulkan/wgpu interop or passthrough and need to enable features/extensions that wgpu does not expose, there is a new wgpu_hal::vulkan::Adapter::open_with_callback that allows the user to modify the pnext chains and extension lists populated by wgpu before we create a vulkan device. This should vastly simplify the experience, as previously you needed to create a device yourself.

Underlying api interop is a quickly evolving space, so we welcome all feedback!

type VkApi = wgpu::hal::api::Vulkan;
let adapter: wgpu::Adapter = ...;

let mut buffer_device_address_create_info = ash::vk::PhysicalDeviceBufferDeviceAddressFeatures { .. };
let hal_device: wgpu::hal::OpenDevice<VkApi> = adapter
    .as_hal::<VkApi>()
    .unwrap()
    .open_with_callback(
        wgpu::Features::empty(),
        &wgpu::MemoryHints::Performance,
        Some(Box::new(|args| {
            // Add the buffer device address extension.
            args.extensions.push(ash::khr::buffer_device_address::NAME);
            // Extend the create info with the buffer device address create info.
            *args.create_info = args
                .create_info
                .push_next(&mut buffer_device_address_create_info);
            // We also have access to the queue create infos if we need them.
            let _ = args.queue_create_infos;
        })),
    )
    .unwrap();

let (device, queue) = adapter
    .create_device_from_hal(hal_device, &wgpu::DeviceDescriptor { .. })
    .unwrap();

More examples of this

By @​Vecvec in #​7829.

Naga
General
  • Add support for astc-sliced-3d feature. By @​mehmetoguzderin in #​7577
  • Added wgpu_hal::dx12::Adapter::as_raw(). By @​tronical in ##​7852
  • Add support for rendering to slices of 3D texture views and single layered 2D-Array texture views (this requires VK_KHR_maintenance1 which should be widely available on newer drivers). By @​teoxoy in #​7596
  • Add extra acceleration structure vertex formats. By @​Vecvec in #​7580.
  • Add acceleration structure limits. By @​Vecvec in #​7845.
  • Add support for clip-distances feature for Vulkan and GL backends. By @​dzamkov in #​7730
  • Added wgpu_types::error::{ErrorType, WebGpuError} for classification of errors according to WebGPU's GPUError's classification scheme, and implement WebGpuError for existing errors. This allows users of wgpu-core to offload error classification onto the WGPU ecosystem, rather than having to do it themselves without sufficient information. By @​ErichDonGubler in #​6547.
Bug Fixes
General
  • Fix error message for sampler array limit. By @​LPGhatguy in #​7704.
  • Fix bug where using BufferSlice::get_mapped_range_as_array_buffer() on a buffer would prevent you from ever unmapping it. Note that this API has changed and is now BufferView::as_uint8array().
Naga
DX12
  • Get vertex_index & instance_index builtins working for indirect draws. By @​teoxoy in #​7535
Vulkan
Metal
WebGPU
Changes
  • Loosen Viewport validation requirements to match the new specs. By @​ebbdrop in #​7564
  • wgpu and deno_webgpu now use wgpu-types::error::WebGpuError to classify errors. Any changes here are likely to be regressions; please report them if you find them! By @​ErichDonGubler in #​6547.
General
  • Support BLAS compaction in wgpu. By @​Vecvec in #​7285.
  • Removed MaintainBase in favor of using PollType. By @​waywardmonkeys in #​7508.
  • The destroy functions for buffers and textures in wgpu-core are now infallible. Previously, they returned an error if called multiple times for the same object. This only affects the wgpu-core API; the wgpu API already allowed multiple destroy calls. By @​andyleiserson in #​7686 and #​7720.
  • Remove CommandEncoder::build_acceleration_structures_unsafe_tlas in favour of as_hal and apply
    simplifications allowed by this. By @​Vecvec in #​7513
  • The type of the size parameter to copy_buffer_to_buffer has changed from BufferAddress to impl Into<Option<BufferAddress>>. This achieves the spec-defined behavior of the value being optional, while still accepting existing calls without changes. By @​andyleiserson in #​7659.
  • To bring wgpu's error reporting into compliance with the WebGPU specification, the error type returned from some functions has changed, and some errors may be raised at a different time than they were previously.
    • The error type returned by many methods on CommandEncoder, RenderPassEncoder, ComputePassEncoder, and RenderBundleEncoder has changed to EncoderStateError or PassStateError. These functions will return the Ended variant of these errors if called on an encoder that is no longer active. Reporting of all other errors is deferred until a call to finish().
    • Variants holding a CommandEncoderError in the error enums ClearError, ComputePassErrorInner, QueryError, and RenderPassErrorInner have been replaced with variants holding an EncoderStateError.
    • The definition of enum CommandEncoderError has changed significantly, to reflect which errors can be raised by CommandEncoder.finish(). There are also some errors that no longer appear directly in CommandEncoderError, and instead appear nested within the RenderPass or ComputePass variants.
    • CopyError has been removed. Errors that were previously a CopyError are now a CommandEncoderError returned by finish(). (The detailed reasons for copies to fail were and still are described by TransferError, which was previously a variant of CopyError, and is now a variant of CommandEncoderError).
Naga
  • Mark readonly_and_readwrite_storage_textures & packed_4x8_integer_dot_product language extensions as implemented. By @​teoxoy in #​7543
  • naga::back::hlsl::Writer::new has a new pipeline_options argument. hlsl::PipelineOptions::default() can be passed as a default. The shader_stage and entry_point members of pipeline_options can be used to write only a single entry point when using the HLSL and MSL backends (GLSL and SPIR-V already had this functionality). The Metal and DX12 HALs now write only a single entry point when loading shaders. By @​andyleiserson in #​7626.
  • Implemented early_depth_test for SPIR-V backend, enabling SHADER_EARLY_DEPTH_TEST for Vulkan. Additionally, fixed conservative depth optimizations when using early_depth_test. The syntax for forcing early depth tests is now @early_depth_test(force) instead of @early_depth_test. By @​dzamkov in #​7676.
  • ImplementedLanguageExtension::VARIANTS is now implemented manually rather than derived using strum (allowing strum to become a dev-only dependency) so it is no longer a member of the strum::VARIANTS trait. Unless you are using this trait as a bound this should have no effect.
  • Compaction changes, by @​andyleiserson in #​7703:
    • process_overrides now compacts the module to remove unused items. It is no longer necessary to supply values for overrides that are not used by the active entry point.
    • The compact Cargo feature has been removed. It is no longer possible to exclude compaction support from the build.
    • compact now has an additional argument that specifies whether to remove unused functions, globals, and named types and overrides. For the previous behavior, pass KeepUnused::Yes.
D3D12
Vulkan
HAL
Documentation
General

Configuration

📅 Schedule: Branch creation - Between 12:00 AM and 03:59 AM, only on Monday ( * 0-3 * * 1 ) (UTC), 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.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

@bonohub13
Copy link
Contributor

bonohub13 commented Jul 20, 2025

@Yatekii
I added fixes for examples and updated the version of wgpu to v26.0.1
Plz feel free to use this commit
bonohub13@18cdab1

@cwfitzgerald
Copy link
Collaborator

@bonohub13 could you file a PR?

@bonohub13
Copy link
Contributor

@Yatekii np. Filed the PR here #126

Copy link
Contributor Author

renovate bot commented Jul 22, 2025

Renovate Ignore Notification

Because you closed this PR without merging, Renovate will ignore this update. You will not get PRs for any future 26.x releases. But if you manually upgrade to 26.x then Renovate will re-enable minor and patch updates automatically.

If you accidentally closed this PR, or if you changed your mind: rename this PR to get a fresh replacement PR.

@renovate renovate bot deleted the renovate/wgpu-26.x branch July 22, 2025 14:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants