Reverting last change (sorry about this, but changes should

really go in trunk first)
This commit is contained in:
yabause 2009-01-01 22:13:59 +00:00
parent 34f0bd9a80
commit bd55e67a3c
1 changed files with 12 additions and 13 deletions

View File

@ -307,20 +307,17 @@ static GLuint texBlendLoc;
static void createShaders() static void createShaders()
{ {
const char *extString;
hasShaders = true; hasShaders = true;
extString = (const char*)glGetString(GL_EXTENSIONS); if (glCreateShader == NULL || //use ==NULL instead of !func to avoid always true warnings for some systems
if ((strstr(extString, "GL_ARB_shading_language_100") == NULL) || glShaderSource == NULL ||
(strstr(extString, "GL_ARB_shader_objects") == NULL) || glCompileShader == NULL ||
(strstr(extString, "GL_ARB_vertex_shader") == NULL) || glCreateProgram == NULL ||
(strstr(extString, "GL_ARB_fragment_shader") == NULL)) glAttachShader == NULL ||
{ glLinkProgram == NULL ||
INFO("Your system doesn't support OpenGL shaders. Using fixed pipeline.\n"); glUseProgram == NULL ||
hasShaders = false; glGetShaderInfoLog == NULL)
return; NOSHADERS(1);
}
vertexShaderID = glCreateShader(GL_VERTEX_SHADER); vertexShaderID = glCreateShader(GL_VERTEX_SHADER);
if(!vertexShaderID) if(!vertexShaderID)
@ -429,7 +426,9 @@ static char OGLInit(void)
#endif #endif
/* Create the shaders */ /* Create the shaders */
createShaders(); //as a hack for 0.9 release, we're disabling shaders.
hasShaders = false;
//createShaders();
/* Assign the texture units : 0 for main textures, 1 for toon table */ /* Assign the texture units : 0 for main textures, 1 for toon table */
/* Also init the locations for some variables in the shaders */ /* Also init the locations for some variables in the shaders */