#ifndef SHADERSYSTEM_H
#define SHADERSYSTEM_H

#include <string>
#include <vector>

#include "shader.h"

class ShaderSystem
{
public:
	ShaderSystem();
	~ShaderSystem();

	void Init();
	void Shutdown();

	Shader* CreateShader(const char* name, const char* vsfilepath, const char* psfilepath, InputLayoutDesc_t* inputLayout = nullptr, int inputLayoutCount = 0);

	void SetShader(const Shader* shader);

	void SetUniformSampler( const Shader* shader, ShaderSamplers_t sampler, int index );
	void SetUniformFloat4( const Shader* shader, ShaderUniform_t uniform, const void* data );
	void SetUniformMatrix( const Shader* shader, ShaderUniform_t uniform, const void* data, int numMatrices = 1 );

private:
	std::vector<Shader*> m_shaders;
};

extern ShaderSystem* g_shaderSystem;

#endif // !SHADERSYSTEM_H
