diff options
Diffstat (limited to 'tools/render-test/render.h')
| -rw-r--r-- | tools/render-test/render.h | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/tools/render-test/render.h b/tools/render-test/render.h index afa279c66..7f8f2fffa 100644 --- a/tools/render-test/render.h +++ b/tools/render-test/render.h @@ -20,8 +20,8 @@ struct ShaderCompileRequest struct EntryPoint { - char const* name; - char const* profile; + char const* name = nullptr; + char const* profile = nullptr; SourceInfo source; }; @@ -29,6 +29,7 @@ struct ShaderCompileRequest SourceInfo source; EntryPoint vertexShader; EntryPoint fragmentShader; + EntryPoint computeShader; }; class ShaderCompiler @@ -47,6 +48,7 @@ enum class BufferFlavor { Constant, Vertex, + Storage, }; struct BufferDesc @@ -66,6 +68,8 @@ struct InputElementDesc enum class MapFlavor { + HostRead, + HostWrite, WriteDiscard, }; @@ -108,13 +112,17 @@ public: virtual void setShaderProgram(ShaderProgram* program) = 0; virtual void setConstantBuffers(UInt startSlot, UInt slotCount, Buffer* const* buffers, UInt const* offsets) = 0; - + virtual void setStorageBuffers(UInt startSlot, UInt slotCount, Buffer* const* buffers, UInt const* offsets) = 0; inline void setConstantBuffer(UInt slot, Buffer* buffer, UInt offset = 0) { setConstantBuffers(slot, 1, &buffer, &offset); } - + inline void setStorageBuffer(UInt slot, Buffer* buffer, UInt offset = 0) + { + setStorageBuffers(slot, 1, &buffer, &offset); + } virtual void draw(UInt vertexCount, UInt startVertex = 0) = 0; + virtual void dispatchCompute(int x, int y, int z) = 0; }; } // renderer_test |
