charcoal/OpenGLEngine/VertexFragmentShaderProgram.cpp

16 lines
475 B
C++
Raw Normal View History

#include "VertexFragmentShaderProgram.h"
#include "Util.h"
namespace charcoal
{
VertexFragmentShaderProgram::VertexFragmentShaderProgram(const std::string& vertex_shader_path, const std::string& fragment_shader_path)
: ShaderProgram(),
m_vertex_shader(Util::load_file(vertex_shader_path), VERTEX_SHADER),
m_fragment_shader(Util::load_file(fragment_shader_path), FRAGMENT_SHADER)
{
attach_shader(m_vertex_shader);
attach_shader(m_fragment_shader);
link();
}
}