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

Generate constant buffer layout type for marshalling #574

Merged
merged 7 commits into from
Sep 28, 2023

Conversation

Sergio0694
Copy link
Owner

Description

This PR updates the D2D1 shader generator to emit a type mapping the constant buffer of a shader. This is then used as local to perform marshalling back and forth between the managed instance and the native buffer. This results in much easier to read and understand generated code, and better perform (due to no stack alloc, more compact codegen, etc.).

@Sergio0694 Sergio0694 added the optimization 🚀 Performance improvement to existing APIs label Sep 28, 2023
@Sergio0694 Sergio0694 merged commit 44e36eb into main Sep 28, 2023
@Sergio0694 Sergio0694 deleted the dev/constant-buffer-type-layout branch September 28, 2023 09:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
optimization 🚀 Performance improvement to existing APIs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant