summaryrefslogtreecommitdiff
path: root/Runtime/Graphics/ShaderCompiler.h
diff options
context:
space:
mode:
authorchai <chaifix@163.com>2021-10-28 11:09:59 +0800
committerchai <chaifix@163.com>2021-10-28 11:09:59 +0800
commit92dd401d75e19281dc7a01492ab3c0996de330fc (patch)
tree489abcea143fc269e77a0553c6f12ec821bf2feb /Runtime/Graphics/ShaderCompiler.h
parentf6327c0948d666a4b61358c7aefed36eb070198d (diff)
*misc
Diffstat (limited to 'Runtime/Graphics/ShaderCompiler.h')
-rw-r--r--Runtime/Graphics/ShaderCompiler.h12
1 files changed, 9 insertions, 3 deletions
diff --git a/Runtime/Graphics/ShaderCompiler.h b/Runtime/Graphics/ShaderCompiler.h
index 2917cf4..f4dc0a5 100644
--- a/Runtime/Graphics/ShaderCompiler.h
+++ b/Runtime/Graphics/ShaderCompiler.h
@@ -1,5 +1,6 @@
#pragma once
+#include <exception>
#include <string>
#include "Runtime/Threading/Mutex.h"
#include "Runtime/Threading/Job.h"
@@ -20,14 +21,19 @@ class CompileGLSLShaderJob : public Job
};
-enum EGLSLCompileErrorCode
+class GLSLCompileException : std::exception
{
- Success = 0,
+public:
+ GLSLCompileException(const char* what)
+ : std::exception(what)
+ {
+ }
+
};
class GLSLCompiler
{
public:
- static int Compile(std::string& src, std::string& vsh, std::string& fsh);
+ static void Compile(std::string& src, std::string& vsh, std::string& fsh)/*throw GLSLCompileException*/;
};