Initial commit: Final state of the master project
This commit is contained in:
27
Research/shaders/ShaderLoader.h
Normal file
27
Research/shaders/ShaderLoader.h
Normal file
@@ -0,0 +1,27 @@
|
||||
#pragma once
|
||||
#include <string>
|
||||
#include <map>
|
||||
|
||||
class ShaderLoader {
|
||||
|
||||
public:
|
||||
static void Create();
|
||||
static void Destroy();
|
||||
static ShaderLoader* Instance();
|
||||
unsigned LoadShader(const char* vertexFileName = "Shader.vert", const char* fragmentFileName = "Shader.frag", const std::map<std::string, std::string> additionalProperties = std::map<std::string, std::string>());
|
||||
|
||||
void SetShaderPath(std::string shaderPath);
|
||||
std::string GetShaderPath();
|
||||
protected:
|
||||
|
||||
private:
|
||||
ShaderLoader();
|
||||
~ShaderLoader();
|
||||
void ParseProperties(std::string &line, char delimiter, const std::map<std::string, std::string> additionalProperties = std::map<std::string, std::string>());
|
||||
|
||||
static ShaderLoader* mInstance;
|
||||
|
||||
std::string mShaderPath;
|
||||
|
||||
bool verbose;
|
||||
};
|
||||
Reference in New Issue
Block a user