added asset loading class, zoom factor, vbo switch, shader version

This commit is contained in:
2017-03-13 01:16:20 +00:00
parent a2a221b17a
commit ee6d352fc6
25 changed files with 345 additions and 108 deletions

View File

@@ -22,7 +22,7 @@ bool Shader::create(const char* vertex, const char* fragment)
glGetShaderiv(vs, GL_COMPILE_STATUS, &status);
glGetShaderInfoLog(vs, sizeof(infolog), &infolen, infolog);
if (infolen > 0)
printf("VERTEX SHADER:\n%s", infolog);
LOG("VERTEX SHADER:\n%s", infolog);
if (status == 0)
{
glDeleteShader(vs);
@@ -41,7 +41,7 @@ bool Shader::create(const char* vertex, const char* fragment)
glGetShaderiv(fs, GL_COMPILE_STATUS, &status);
glGetShaderInfoLog(fs, sizeof(infolog), &infolen, infolog);
if (infolen > 0)
printf("FRAGMENT SHADER:\n%s", infolog);
LOG("FRAGMENT SHADER:\n%s", infolog);
if (status == 0)
{
glDeleteShader(vs);
@@ -68,7 +68,7 @@ bool Shader::create(const char* vertex, const char* fragment)
glGetProgramiv(ps, GL_LINK_STATUS, &status);
glGetProgramInfoLog(ps, sizeof(infolog), &infolen, infolog);
if (infolen > 0)
printf("LINK SHADER:\n%s", infolog);
LOG("LINK SHADER:\n%s", infolog);
if (status == 0)
{
glDeleteProgram(ps);