GLUtil: Encapsulate functions in a namespace

This commit is contained in:
Stenzek
2018-03-10 14:52:48 +10:00
parent e31cc1f679
commit 51a586d11a
4 changed files with 11 additions and 12 deletions

View File

@ -11,12 +11,14 @@
std::unique_ptr<cInterfaceBase> GLInterface;
namespace GLUtil
{
void InitInterface()
{
GLInterface = HostGL_CreateGLInterface();
}
GLuint OpenGL_CompileProgram(const std::string& vertexShader, const std::string& fragmentShader)
GLuint CompileProgram(const std::string& vertexShader, const std::string& fragmentShader)
{
// generate objects
GLuint vertexShaderID = glCreateShader(GL_VERTEX_SHADER);
@ -100,3 +102,4 @@ GLuint OpenGL_CompileProgram(const std::string& vertexShader, const std::string&
return programID;
}
}