This is particularly useful downstream for distinguishing between
instances of these types.
I was unsure about `Device` as I noticed it has a `Temp` field that
looks like it might eventually store some non-PartialEq/Hash-friendly
fields.
Let me know if you'd like me to add a derive for `Device` or if there
are any issues with those I have updated.
518: Wholesome spec update r=grovesNL a=kvark
Addresses https://github.com/gfx-rs/wgpu-rs/issues/196
Biggest change is that buffer binding is done one by one. There is a number of renamings of the fields, also the binding types are expanded.
Co-authored-by: Dzmitry Malyshau <kvarkus@gmail.com>
514: Move some types into shared wgpu-types crate r=kvark a=grovesNL
As we discussed a while ago, we need to be able to share some types between wgpu-core/wgpu-native/wgpu-remote/wgpu-rs.
The problem is that we want to avoid a dependency on wgpu-core and wgpu-native when building [wgpu-rs for the wasm32-unknown-unknown target](https://github.com/gfx-rs/wgpu-rs/issues/101). We can avoid this by moving all shared types into a separate crate which is exposed on all targets.
Let me know if we should use some other approach or organize the types somehow. This isn't complete yet, but it might be easier to integrate this over several PRs instead of diverging my branch too far.
Co-authored-by: Joshua Groves <josh@joshgroves.com>
192: Explicitly declare vertex attribute descriptors in cube example r=kvark a=aloucks
The new `vertex_attr_array!` macro is pretty wonderful, but it's nice to have at least one reference example of how `VertexAttributeDescriptor`s are constructed.
Co-authored-by: Aaron Loucks <aloucks@cofront.net>
512: Add PresentMode::Mailbox r=kvark a=aloucks
@kvark
Would you be open to renaming the presents modes to match the vulkan/gfx-hal nomenclature? Considering these aren't part of the webgpu spec, I think it would make more sense to keep things consistent.
I can update this PR if you're good with it.
```rust
pub enum PresentMode {
/// The presentation engine does **not** wait for a vertical blanking period and
/// the request is presented immediately. This is a low-latency presentation mode,
/// but visible tearing may be observed. Will fallback to `Fifo` if unavailable on the
/// selected platform and backend. Not optimal for mobile.
Immediate = 0,
/// The presentation engine waits for the next vertical blanking period to update
/// the current image, but frames may be submitted without delay. This is a low-latency
/// presentation mode and visible tearing will **not** be observed. Will fallback to `Fifo`
/// if unavailable on the selected platform and backend. Not optimal for mobile.
Mailbox = 1,
/// The presentation engine waits for the next vertical blanking period to update
/// the current image. The framerate will be capped at the display refresh rate,
/// corresponding to the `VSync`. Tearing cannot be observed. Optimal for mobile.
Fifo = 2,
}
```
Co-authored-by: Aaron Loucks <aloucks@cofront.net>
189: Reexport Backend and DeviceType from wgpu-core r=kvark a=aloucks
These types are exposed on the `AdaptorInfo` struct.
Co-authored-by: Aaron Loucks <aloucks@cofront.net>
507: Update logo and move bindings section r=kvark a=grovesNL
- Adjust the logo slightly
- Move the bindings section up slightly to hopefully reduce confusion for users coming to gfx-rs/wgpu looking for the Rust bindings (gfx-rs/wgpu-rs)
- Also added some experimental Julia bindings
- Open to other ideas how we can improve the repository naming confusion, though long term I think we may want to adjust the naming somehow (like we talked about before the sync was setup)
[Rendered](8b19724364/README.md)
Co-authored-by: Joshua Groves <josh@joshgroves.com>
185: Update readme r=kvark a=grovesNL
Add logo and update readme text a bit (link to WASM progress, reword examples section slightly, etc.)
[Rendered](ea4bf79ff7/README.md)
Co-authored-by: Joshua Groves <josh@joshgroves.com>
184: added test to hello-compute example r=kvark a=emmetthebarnraiser
I wasn't exactly sure of the proper way to test async stuff, but this is a strategy that seemed to work for me. Let me know if there is anything you would like me to change, or if this isn't something that you would like to add to the examples!
Co-authored-by: Brian Frazho <befrazho@gmail.com>
506: Bug 1614702 - WebGPU textures, texture views, and samplers r=gecko a=kvark
This is a commit cherry-picked from #504
Co-authored-by: Dzmitry Malyshau <dmalyshau@mozilla.com>
183: Expose `enumerate_adapters`. r=kvark a=daxpedda
Depends on gfx-rs/wgpu#505.
Use case was to give end user the ability to choose which GPU to use for an application.
Co-authored-by: daxpedda <daxpedda@gmail.com>
505: Expose `Global::enumerate_adapters`. r=kvark a=daxpedda
Expose `enumerate_adapters` to use it in `wgpu-rs`.
Issue was that directly accessing `wgpu-core` wasn't possible because an instantiation of `Global` was needed.
Co-authored-by: daxpedda <daxpedda@gmail.com>
501: Update WebGPU to mozilla-central from hg rev 0f1a8e4c6a76b3b0b16902c7fdfe2356c60ca351 r=kvark a=staktrace
This merge commit should get tagged as `mozilla-0f1a8e4c6a76b3b0b16902c7fdfe2356c60ca351`.
Co-authored-by: Kartikaya Gupta <kgupta@mozilla.com>
179: Add vertex_attr_array macro r=kvark a=dhardy
Specifying `VertexAttributeDescriptor` arrays is tedious, and for no good reason. This PR adds a macro to do the job.
All examples tested. Documentation is short but better than the standard for this crate I feel. 😉
Co-authored-by: Diggory Hardy <git@dhardy.name>
497: Catch swapchain output being dropped too early r=kvark a=kvark
Prevents a common case where the swapchain frame is dropped before the submission. This is not comprehensive yet, but it should be helpful.
Co-authored-by: Dzmitry Malyshau <kvarkus@gmail.com>