Commit Graph
1234 Commits
Author SHA1 Message Date
Connor Fitzgerald dc01e6e213 Normalize logging levels (#8579) 2025-11-27 10:55:02 +01:00
Martin Svanberg f114138e52 Support STORAGE_RESOURCE_BINDING_ARRAY on Metal (#8464) 2025-11-26 20:18:10 -05:00
Eric Engestrom 803e48ca3b hal/vulkan: fix invalid request of VK_EXT_physical_device_drm as an instance extension (#8554) 2025-11-26 17:52:14 -05:00
Alix Bott 43c5d27219 fix double window class registration (#8548) 2025-11-26 17:51:41 -05:00
Andreas Reich 7572bf2264 Remove unnecessary pin (#8535) 2025-11-16 22:17:26 +00:00
Inner DaemonsandAndreas Reich 05369a6b83 Multiview on DX12 (#8495)
Co-authored-by: Andreas Reich <r_andreas2@web.de>
2025-11-16 17:46:52 +01:00
Anton Kushakov c78f944f2f Fix: Race condition when compute shader writes to texture. (#8527) 2025-11-16 16:29:41 +01:00
d0cf78c8c8 [hal/metal] Mesh Shaders (#8139)
Co-authored-by: Connor Fitzgerald <connorwadefitzgerald@gmail.com>
Co-authored-by: Magnus <85136135+SupaMaggie70Incorporated@users.noreply.github.com>
2025-11-14 23:11:43 -05:00
92fa99af1b Switch to pipeline stream desc for dx12 pipeline creation (#8377)
Co-authored-by: Inner Daemons <magnus.larsson.mn@gmail.com>
Co-authored-by: Connor Fitzgerald <connorwadefitzgerald@gmail.com>
2025-11-14 21:35:28 +00:00
Vecvec efca3f5066 [spirv] Make ray queries safer (#8390) 2025-11-13 00:33:32 -05:00
a05c70cef7 WGSL parsing for mesh shaders (#8370)
Co-authored-by: Jim Blandy <jimb@red-bean.com>
Co-authored-by: Erich Gubler <erichdongubler@gmail.com>
Co-authored-by: Connor Fitzgerald <connorwadefitzgerald@gmail.com>
Co-authored-by: SupaMaggie70Incorporated <85136135+SupaMaggie70Incorporated@users.noreply.github.com>
2025-11-12 21:06:20 -05:00
s-ol d017d48b45 Allow passing external_memory in vulkan-hal::Device::texture_from_raw() (#8512) 2025-11-11 11:01:02 -05:00
Erich Gubler 9447a22288 refactor(gles): document Buffer::map_flags (#8455) 2025-11-05 21:11:34 +00:00
Marijn Suijten 59a03eaf2f [d3d12 wgl] Upgrade to windows 0.62 crates (#6876)
* [d3d12 wgl] Upgrade to `windows 0.59` crates

https://github.com/microsoft/windows-rs/releases/tag/0.61.0

The latest `windows 0.59` and `windows-core 0.59` crates were
just released (strangely tagged `0.61`), including some minor code
improvements for us.  The MSRV has been bumped to `1.74`, but `wgpu` is
already on `1.76` anyway.

* [d3d12 wgl] Upgrade to `windows 0.61` crates

https://github.com/microsoft/windows-rs/releases/tag/63

* [d3d12 wgl] Upgrade to windows 0.62 crates

https://github.com/microsoft/windows-rs/releases/tag/69
2025-11-05 11:47:31 -05:00
Connor Fitzgerald 71b5fb0ad9 Update WARP (#8444) 2025-11-04 23:57:49 -05:00
ad0f3111b7 Add multiview limits and tests (#8206)
Co-authored-by: Andreas Reich <r_andreas2@web.de>
Co-authored-by: Magnus <85136135+SupaMaggie70Incorporated@users.noreply.github.com>
2025-11-01 12:08:15 +00:00
bf9f7524ec Add mesh shading info to naga IR (#8104)
Co-authored-by: Jim Blandy <jimb@red-bean.com>
Co-authored-by: SupaMaggie70Incorporated <85136135+SupaMaggie70Incorporated@users.noreply.github.com>
2025-10-29 14:49:51 -04:00
Mikołaj Radkowski e7fcb94888 Make multi-planar textures renderable (#8307) 2025-10-29 13:33:48 -04:00
atlv ddcd89fd69 Implement shader barycentrics (#8320) 2025-10-29 13:15:21 -04:00
Connor Fitzgerald ef1d31955a Factor out swapchain to abstracted interface (#8356) 2025-10-26 22:02:40 -04:00
charlotte 🌸 0810110bd7 Add pci bus and device uuid to AdapterInfo (#8290) 2025-10-24 11:53:44 -04:00
Connor Fitzgerald b3d94317d4 [hal/vulkan] Wait for fence signalled in vkAcquireNextImage (#8420) 2025-10-22 23:16:09 -04:00
Jerzy Wilczek a70b8336c0 fix: Move DropGuards to the end of their parent structs. (#8353) 2025-10-16 15:58:18 -04:00
OpsticandConnor Fitzgerald f0209e3db8 Add support for transient textures on Vulkan and Metal (#8247)
Co-authored-by: Connor Fitzgerald <connorwadefitzgerald@gmail.com>
2025-10-16 19:50:01 +00:00
Inner Daemons 70e2302ace Made conv public (#8364) 2025-10-16 04:07:12 +00:00
Erich Gubler 54ded60d8e fix(dx12): align tex. <-> buf. copies via intermediate buffer if !UnrestrictedBufferTextureCopyPitchSupported 2025-10-14 09:39:56 -04:00
Erich Gubler ce69059fdf refactor(dx12): extract copy_aligned in copy_texture_to_buffer 2025-10-14 09:39:56 -04:00
Erich Gubler 4db543cf9b refactor(hal): impl. From conversions b/w wgh::CopyExtent and wgt::Extent3d 2025-10-14 09:39:56 -04:00
Erich Gubler fd7530a011 refactor(dx12): lower list extraction for copies between textures and buffers 2025-10-14 09:39:56 -04:00
Erich Gubler 517018e9ae refactor(dx12): detect UnrestrictedBufferTextureCopyPitchSupported 2025-10-14 09:39:56 -04:00
Jim Blandy 3a78566105 [wgpu-hal] Fix mismatched_lifetime_syntaxes lint in gles. (#8324)
Add a placeholder lifetime to `AdapterContext::get_without_egl_lock`
to address Clippy's concerns about easy-to-misread function
signatures.
2025-10-13 13:21:54 -04:00
Sam a8f51f8fd1 Split MipmapFilterMode from FilterMode (#8314) 2025-10-08 18:06:33 +02:00
renovate[bot]andAndreas Reich 854664a90d chore(deps): update crate-ci/typos action to v1.37.3 (#8306)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Andreas Reich <r_andreas2@web.de>
2025-10-06 19:32:39 +00:00
Connor Fitzgerald e73d0558f0 Fix docs.rs build (#8292) 2025-10-06 13:11:48 -04:00
David Stern b3c6a0b5cc Gate DX12 mesh shader command signature initialization on device support. (#8297) 2025-10-04 00:41:58 +00:00
Jim Blandy 43eccd28f8 [naga] Remove naga::path_like. Use String instead. (#8284)
Delete the `naga::path_like` module, and simply using `String` and
`str` instead.

Nothing in Naga uses `Path` or `PathBuf` methods; indeed, Naga only
converts these values back and forth from string-like types with
`to_string_lossy` and `into`, such that using string-like, rather than
path-like, types actually simplifies the code.

This also avoids dead code warnings starting in Rust 1.89 that would
otherwise require distracting `#[cfg_attr]` conditionals.
2025-10-01 18:08:18 +02:00
Andreas Reich 00ea850d79 Allow timeouting on poll (#8282) 2025-10-01 07:19:24 +00:00
Marijn Suijten ea80c7dbc3 hal/vulkan: Accurately map all formats except fp16 to use the non-linear sRGB color space (#8226) 2025-09-29 11:50:10 -04:00
Vecvec f1c876c875 Create a seperate event for each fence wait. (#8273)
* create an event per fence wait

* Use seperate event for each `wait_for_present_queue_idle` call.

* changelog
2025-09-29 11:38:33 -04:00
Teodor Tanasoaia ce96254f4f [msl] fix vertex pulling with a stride of 0 (#8265) 2025-09-26 13:37:37 -04:00
Teodor Tanasoaia 3375284f16 [D3D12] fix setting vertex buffer array stride if 0 (#8260) 2025-09-26 11:45:37 +00:00
Xiaopeng Li 990aef977e Expose external memory of vulkan texture (#8257) 2025-09-25 08:27:54 -04:00
05cc6dca82 [hal/dx12] Mesh Shaders (#8110)
* Features and draw commands added

* Tried to implement the pipeline creation (completely untested)

* Fixed clippy issues

* Fixed something I think

* A little bit of work on the mesh shader example (currently doesn't work on dx12)

* Reached a new kind of error state

* Fixed an alignment issue

* DirectX 12 mesh shaders working :party:

* Removed stupid change and updated changelog

* Fixed typo

* Added backends option to example framework

* Removed silly no write fragment shader from tests to see if anything breaks

* Tried to make mesh shader tests run elsewhere too

* Removed printlns and checked that dx12 mesh shader tests run

* Documented very strange issue

* I'm so lost

* Fixed stupid typos

* Fixed all issues

* Removed unnecessary example stuff, updated tests

* Updated typos.toml

* Updated limits

* Apply suggestion from @cwfitzgerald

Co-authored-by: Connor Fitzgerald <connorwadefitzgerald@gmail.com>

* Apply suggestion from @cwfitzgerald

Co-authored-by: Connor Fitzgerald <connorwadefitzgerald@gmail.com>

* Removed supported backends, made example & tests always pass the filename to shader compilers

* Removed excessive bools in test params

* Added new tests to the list

* I'm a sinner for this one (unused import)

* Replaced random stuff with test params hashing

* Updated typos.toml

* Updated -Fo typo thing

* Actually fixed typo issue this time

* Update CHANGELOG.md

Co-authored-by: Connor Fitzgerald <connorwadefitzgerald@gmail.com>

* Update tests/tests/wgpu-gpu/mesh_shader/mod.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update wgpu-hal/src/dx12/mod.rs

Co-authored-by: Connor Fitzgerald <connorwadefitzgerald@gmail.com>

* Addressed comments

* Lmao

---------

Co-authored-by: Connor Fitzgerald <connorwadefitzgerald@gmail.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-09-25 03:24:56 +00:00
Jay McCarthyandConnor Fitzgerald 6ef8e1f103 Expose raw handles (#8174)
Co-authored-by: Connor Fitzgerald <connorwadefitzgerald@gmail.com>
2025-09-24 21:16:47 +00:00
Jamie Nicol ba0b6b9b0e [vulkan, naga spv-out] Remap resource bindings
In order to support external textures, we must be able to map a single
external texture resource binding to multiple Vulkan descriptors. This
means we must be able to override the `Binding` and `DescriptorSet`
values for global variables when generating SPIR-V, rather than simply
passing through the group and binding values from Naga IR.

This patch extends the existing SPIR-V Naga backend's `BindingMap` to
contain a descriptor set and binding value in addition to the existing
array size. When creating BindGroupLayouts/BindGroups we use a
sequentially incrementing value for each entry's binding value,
continuing to just use the bind group index as the descriptor set
value.

The Naga backend looks up each resource in the map when emitting its
`Binding` and `DescriptorSet` decorations. If the entry cannot be
found in the map, it will either error or emit fake bindings based on
its configuration.
2025-09-24 17:55:35 +02:00
Jamie Nicol 725549363b [vulkan] Use corresponding bind group layout entries when creating bind groups, rather than list of vk::DescriptorType
This is a refactoring of Vulkan BindGroupLayout and BindGroup creation
in preparation for implementing external texture support.

Currently when creating a BindGroupLayout the Vulkan backend creates a
list of the vk::DescriptorType for each entry, as well as the count, for
binding arrays. Then when creating the BindGroup, it iterates through
this list and does whatever it needs to do for each entry based on these
values.

In order to support external textures, we will have to create multiple
descriptors for each BindingType::ExternalTexture. This means we cannot
map each binding type to a single Vulkan descriptor type. Instead, store
the list of BindGroupLayoutEntries on the BindGroupLayout and use those
when creating the BindGroup, using the same "layout_and_entry_iter"
idiom used by other backends. In subsequent patches this will allow us
to create multiple descriptors for a single resource binding.
2025-09-24 17:55:35 +02:00
Andy Leiserson aee8cd1650 Lazy-load the dcomp library (#8216) 2025-09-15 11:48:28 -07:00
3902b0c11c Add support for builtin DComp swapchains (#7550)
Co-authored-by: Connor Fitzgerald <connorwadefitzgerald@gmail.com>
Co-authored-by: Marijn Suijten <marijns95@gmail.com>
2025-09-11 00:19:42 +00:00
Lucas Abel e58223bedf [metal] allow access to command buffer (#8166) 2025-08-29 12:32:34 -04:00
Lucas AbelandAndreas Reich cd14b194a4 [egl] get rid of unwrap where possible (#8024)
Co-authored-by: Andreas Reich <r_andreas2@web.de>
2025-08-28 21:59:54 +00:00