3dphotoshoot

view src/opengl.c @ 18:dccbd7d65517

moved to android-19 to make it work with android 4.x
author John Tsiombikas <nuclear@member.fsf.org>
date Wed, 10 Jun 2015 18:53:28 +0300
parents
children
line source
1 #include "opengl.h"
3 static const char *errstr[] = {
4 "GL_INVALID_ENUM",
5 "GL_INVALID_VALUE",
6 "GL_INVALID_OPERATION",
7 "GL_STACK_OVERFLOW",
8 "GL_STACK_UNDERFLOW",
9 "GL_OUT_OF_MEMORY"
10 };
12 const char *glerrstr(int err)
13 {
14 if(!err) {
15 return "no error";
16 }
17 if(err < GL_INVALID_ENUM || err > GL_OUT_OF_MEMORY) {
18 return "unknown error";
19 }
20 return errstr[err - GL_INVALID_ENUM];
21 }