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

Fix segfault with 2d gizmos #8223

Merged
merged 1 commit into from
Mar 29, 2023

Conversation

mockersf
Copy link
Member

Objective

Solution

  • Don't use depth in 2d

@mockersf mockersf added C-Bug An unexpected or incorrect behavior A-Rendering Drawing game state to the screen labels Mar 26, 2023
Copy link
Contributor

@tim-blackbird tim-blackbird left a comment

Choose a reason for hiding this comment

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

I'm glad you managed to find a fix :)

And it might make sense that this would fail since depth_stencil is None for the 2d pipeline, but in that case I figure wgpu is missing some validation logic.
@cwfitzgerald, Does what I said makes sense? Should we open an issue on the wgpu repo?

@lewiszlw
Copy link
Member

Verified, it works for me.

Copy link
Member

@james7132 james7132 left a comment

Choose a reason for hiding this comment

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

Explanation and fix LGTM. Approving based on @lewiszlw's test.

@james7132 james7132 added the S-Ready-For-Final-Review This PR has been approved by the community. It's ready for a maintainer to consider merging it label Mar 28, 2023
@james7132 james7132 added this pull request to the merge queue Mar 29, 2023
Merged via the queue into bevyengine:main with commit 36ada9d Mar 29, 2023
@cwfitzgerald
Copy link

This is definitely something wgpu needs to deal with in some way, afaik it's perfectly legal to write to frag_depth without depth, so we might need to remove it when writing out the MSL or something, or update the spec.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-Rendering Drawing game state to the screen C-Bug An unexpected or incorrect behavior S-Ready-For-Final-Review This PR has been approved by the community. It's ready for a maintainer to consider merging it
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Segmentation Fault on OSX on main branch Segmentation fault when running 2d_gizmos example
5 participants