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 and refactor vulkan constant and storage buffer mapping #240

Merged
merged 1 commit into from
Jan 28, 2025

Conversation

DavidLokison
Copy link
Contributor

No description provided.

@DavidLokison
Copy link
Contributor Author

Reasoning behind the refactoring part of the shader class was to get both constant and storage buffer calculations in a similar shape. I also noticed some consistencies in the other buffers as well, which was the baseline for the idea to add some functions for code that appears the same every time.

So I basically prepared such a change but didn't add too many functions at once now since that would require some more thought.

Also the usage of bindingLayout.binding and block->binding seemed to be somewhat arbitrary. Since they "should" point to the same value it shouldn't be an issue in the long run but I have set them all to block->binding to make it clear that this is indeed the same value.

Copy link
Contributor

@Duttenheim Duttenheim left a comment

Choose a reason for hiding this comment

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

Looks good, greatly simplified this mess! 👍

@DavidLokison
Copy link
Contributor Author

Have rebased the PR to the master as merging was reverting some changes I made which would duplicate some logic. It's good to merge in my opinion.

@kaffeewolf kaffeewolf merged commit f293204 into gscept:master Jan 28, 2025
4 checks passed
@DavidLokison DavidLokison deleted the vulkan branch January 28, 2025 23:28
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