Skip to content
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

Add missing acceleration structure buffer flag #5760

Merged
merged 4 commits into from
Jun 2, 2024

Conversation

Vecvec
Copy link
Contributor

@Vecvec Vecvec commented May 31, 2024

Connections

Description
Newer versions of the vulkan validation layers give this error when running wgpu hal ray-traced-triangle:

[2024-05-31T05:50:53Z ERROR wgpu_hal::vulkan::instance] VALIDATION [VUID-vkGetAccelerationStructureDeviceAddressKHR-pInfo-09542 (0xe4b63bce)]
        Validation Error: [ VUID-vkGetAccelerationStructureDeviceAddressKHR-pInfo-09542 ] | MessageID = 0xe4b63bce | vkGetAccelerationStructureDeviceAddressKHR(): pInfo->accelerationStructure.buffer was created with usage flag(s) VK_BUFFER_USAGE_2_ACCELERATION
_STRUCTURE_STORAGE_BIT_KHR. The Vulkan spec states: The buffer on which pInfo->accelerationStructure was placed must have been created with the VK_BUFFER_USAGE_SHADER_DEVICE_ADDRESS_BIT usage flag (https://www.khronos.org/registry/vulkan/specs/1.3-extensions/html/vkspec.html#VUID-vkGetAccelerationStructureDeviceAddressKHR-pInfo-09542)

This adds the VK_BUFFER_USAGE_SHADER_DEVICE_ADDRESS_BIT flag to fix this error

Testing
No other validation error when running ray-traced-triangle.

Checklist

  • Run cargo fmt.
  • Run cargo clippy. If applicable, add:
    not applicable because this is not on the web
    • --target wasm32-unknown-unknown
    • --target wasm32-unknown-emscripten
  • Run cargo xtask test to run tests.
  • Add change to CHANGELOG.md. See simple instructions inside file. - Should this be done for such a small change?

@Vecvec Vecvec requested a review from a team as a code owner May 31, 2024 06:01
Copy link
Member

@Wumpf Wumpf left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@Wumpf Wumpf enabled auto-merge (squash) June 2, 2024 07:35
@Wumpf Wumpf merged commit 7954a6b into gfx-rs:trunk Jun 2, 2024
25 checks passed
@Vecvec Vecvec deleted the add-buffer-flag branch June 2, 2024 18:25
@Vecvec Vecvec mentioned this pull request Sep 20, 2024
6 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants