diff --git a/src/glfw_shader.cpp b/src/glfw_shader.cpp index a9139b3..f884606 100644 --- a/src/glfw_shader.cpp +++ b/src/glfw_shader.cpp @@ -1,12 +1,19 @@ +// Writing a shader in opengl + #include #include #include #include +static unsigned int CompileShader(unsigned int fragmentShader,const std::string& source){ + auto id = glCreateShader(GL_VERTEX_SHADER); + auto src = source.c_str(); +} static int CreateShader(const std::string& vertexShader, const std::string& fragmentShader){ - unsigned int program = glCreateProgram(); - unsigned int vs = glCreateShader(GL_VERTEX_SHADER); + auto program = glCreateProgram(); + auto vs = CompileShader(GL_VERTEX_SHADER,vertexShader); + } int tests::glfw_shader(unsigned width,unsigned height, std::string title)