This commit is contained in:
2026-09-06 23:40:27 -07:00
parent dc40e973d3
commit 9b1e7d56a3
7 changed files with 196 additions and 2 deletions
+5
View File
@@ -2,6 +2,7 @@
#include <memory>
#include <sophia/types.hpp>
#include <span>
#include <string>
#include <vector>
@@ -37,15 +38,19 @@ class Shader::Builder {
Builder& fromGLSL(const std::string& path);
Builder& fromSPIRV(const std::string& path);
Builder& fromSPIRV(std::vector<u32> spirv);
Builder& fromSPIRV(std::span<const u32> spirv);
Builder& setStage(ShaderStage shaderStage);
std::unique_ptr<Shader> build();
private:
std::string path;
std::vector<u32> embeddedSpirv;
ShaderStage stage;
bool stageSet = false;
bool precompiled = false;
bool embedded = false;
};
} // namespace sophia