-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[gpu.vulkan] new buffer system. how it works is all resource buffers …
…are infact not descriptors, but are BDA-ready. every buffer's address is placed (in order) into a secret meta-buffer which is always binding 0 in all shaders (this is abstracted away in TZSL). now, resource(id = X) const buffer now compile down to GLSL GL_EXT_buffer_reference definitions, and the accumulation of them all defines the meta-buffer shader side (containing simply references to all the buffer resources in order). this does have one drawback: if you have multiple buffer resources, but do not define them all in the shader, then the buffer-references will point to the wrong thing and cause bugs. so there's a new rule: in TZSL shaders if you use a buffer resource in a particular shader, you *must* declare them ALL.
- Loading branch information
Showing
4 changed files
with
175 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters