KStocky / ShaderTestFramework

An automation testing framework for testing shader code
MIT License
20 stars 1 forks source link

Allow Test Writers to set shader parameters and bind resources #24

Open KStocky opened 5 months ago

KStocky commented 5 months ago

Is your feature request related to a problem? Please describe. Currently, there is no way to write shader tests that involve reading data from buffers, using a shader parameter, or adding a define. This limits the cases in which a test can be written for some shader code.

Describe the solution you'd like I would like to allow test writers to be able to create shader resources and bind them to their test shaders in an easy-to-use manner. A design that might work is to provide a way of setting shader parameters on test shaders. Then test writers should probably only be expected to supply a std::vector to the framework for the framework to then create a StructuredBuffer, upload the initial data, and then return the index of that buffer in the global descriptor heap. This index can then be used by the test writer to set their shader parameters.