1
0
mirror of https://github.com/TomHarte/CLK.git synced 2024-12-25 18:30:21 +00:00
CLK/Outputs/CRT/Shader.hpp
2016-02-07 19:21:22 -05:00

31 lines
566 B
C++

//
// Shader.hpp
// Clock Signal
//
// Created by Thomas Harte on 07/02/2016.
// Copyright © 2016 Thomas Harte. All rights reserved.
//
#ifndef Shader_hpp
#define Shader_hpp
#include "OpenGL.hpp"
namespace OpenGL {
class Shader {
public:
Shader(const char *vertex_shader, const char *fragment_shader);
~Shader();
void bind();
GLint get_attrib_location(const char *name);
GLint get_uniform_location(const char *name);
private:
GLuint compile_shader(const char *source, GLenum type);
GLuint _shader_program;
};
}
#endif /* Shader_hpp */