-
Notifications
You must be signed in to change notification settings - Fork 543
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Distinguish STORAGE from STORAGE_READ_WRITE image feature #3559
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
kvark
reviewed
Dec 31, 2020
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for doing this, much needed for good wgpu support!
kvark
reviewed
Jan 3, 2021
Implemented for Vulkan/DX12/DX11 In Vulkan, storage image implies simultaneous read/write access. Other APIs in contrast may allow STORAGE writeonly while disallowing reading.
Wumpf
force-pushed
the
distinguish-rw-storage-texture
branch
from
January 3, 2021 15:35
5ee7d53
to
8b902f5
Compare
kvark
approved these changes
Jan 3, 2021
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great!
bors r+
bors bot
added a commit
to gfx-rs/wgpu
that referenced
this pull request
Jan 6, 2021
1112: Expose adapter specific formats features via Extension, support for storage read+write r=kvark a=Wumpf **Connections** Draft until gfx-rs/gfx#3559 landed (then update and comment two lines in) New & improved replacement for #1109 PR for wgpu-rs to be opened once there's some confidence that this is that it should look like. [Preview](https://github.com/gfx-rs/wgpu-rs/compare/master...Wumpf:texture-format-feature-query?expand=1) **Description** Adapter exposes now per texture format specific features. Feature struct defined as allowed usages + flags. Flags describe only storage texture usage so far. Query not used for validation unless `TEXTURE_ADAPTER_SPECIFIC_FORMAT_FEATURES` feature is enabled on a device. Otherwise uses hardcoded feature set guaranteed by webgpu. Storage read/write binding can then be used as a consequence (storage atomic has no effect yet). **Testing** Manual testing with my fluid sim project through wgpu-rs which covers storage r/w for a few different formats and storage in general for formats that don't support this usage by default at all. Ran tests and a couple of samples to see if anything broke with the feature disabled. Co-authored-by: Andreas Reich <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Implemented for Vulkan/DX12/DX11.
In Vulkan, storage image implies simultaneous read/write access.
Other APIs in contrast may allow STORAGE writeonly while disallowing reading.
Related to gfx-rs/wgpu#1109 - native extension for for read+write storage textures in wgpu native; following comments on the PR I'm redoing it and would need to add this to the hal api.
PR checklist:
make
succeeds (on *nix)make reftests
succeeds