From e646c7cb836cff47740ecd368afbe346d9b9b609 Mon Sep 17 00:00:00 2001
From: Joseph Walton-Rivers <joseph@walton-rivers.uk>
Date: Fri, 22 Apr 2022 19:41:37 +0100
Subject: [PATCH] remove old shader class

---
 include/fggl/gfx/ogl/backend.hpp | 62 --------------------------------
 1 file changed, 62 deletions(-)

diff --git a/include/fggl/gfx/ogl/backend.hpp b/include/fggl/gfx/ogl/backend.hpp
index 7b0225f..570159f 100644
--- a/include/fggl/gfx/ogl/backend.hpp
+++ b/include/fggl/gfx/ogl/backend.hpp
@@ -6,73 +6,11 @@
 
 #include <stdexcept>
 
-
 /**
  * FGGL OpenGL 4.x rendering backend.
  */
 namespace fggl::gfx {
 
-	class Shader {
-		public:
-			Shader();
-			~Shader();
-
-			inline void use() const {
-				glUseProgram(m_handle);
-			}
-
-			inline GLuint uniform(const std::string &name) {
-				GLint loc = glGetUniformLocation(m_handle, name.c_str());
-				if (loc == -1) {
-					throw std::runtime_error("invalid shader uniform");
-				}
-				return loc;
-			}
-
-			inline void setInt(const std::string &name, const GLint value) {
-				setInt(uniform(name), value);
-			}
-
-			inline void setInt(GLuint idx, const GLint value) {
-				glUniform1i(idx, value);
-			}
-
-			inline void setFloat(const std::string &name, const GLfloat value) {
-				setFloat(uniform(name), value);
-			}
-
-			inline void setFloat(GLuint idx, const GLfloat value) {
-				glUniform1f(idx, value);
-			}
-
-			inline void setVec2(const std::string &name, const GLfloat *vec) {
-				setVec2(uniform(name), vec);
-			}
-
-			inline void setVec2(GLuint idx, const GLfloat *vec) {
-				glUniform2f(idx, vec[0], vec[1]);
-			}
-
-			inline void setVec3(const std::string &name, const GLfloat *vec) {
-				setVec3(uniform(name), vec);
-			}
-
-			inline void setVec3(GLuint idx, const GLfloat *vec) {
-				glUniform3f(idx, vec[0], vec[1], vec[2]);
-			}
-
-			inline void setMat4(const std::string &name, const GLfloat *mat) {
-				setMat4(uniform(name), mat);
-			}
-
-			inline void setMat4(GLuint idx, const GLfloat *mat) {
-				glUniformMatrix4fv(idx, 1, GL_FALSE, mat);
-			}
-
-		private:
-			int m_handle;
-	};
-
 }
 
 #endif
-- 
GitLab