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

Eliminate wgpu_core::commands::bundle::State::raw_dynamic_offsets. #2684

Merged
merged 4 commits into from
May 22, 2022

Conversation

jimblandy
Copy link
Member

This depends on #2679.

This vector's contents always ended up identical to the RenderBundleEncoder's BasePass's dynamic_offsets vector, so we can just take values from there instead of copying them.

jimblandy added 4 commits May 20, 2022 23:23
The `dynamic_offsets` and `is_dirty` flags only make sense when the
slot is occupied, so they should be inside the `Option`. This makes
`State::bind` into an `ArrayVec<Option<BindState>>`, and cleans up
various other bits.
This vector's contents always ended up identical to the
`RenderBundleEncoder`'s `BasePass`'s `dynamic_offsets` vector, so
we can just take values from there instead of copying them.
Copy link
Member

@kvark kvark left a comment

Choose a reason for hiding this comment

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

Wanted to scream about why a PR named "eliminate XXX" adds 3x lines more than it removes, but then realized it's classy Jim's comments :)

@kvark kvark merged commit c7872ab into gfx-rs:master May 22, 2022
@jimblandy jimblandy deleted the no-raw-dynamic-offsets branch May 22, 2022 16:00
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.

2 participants