Generate a texenv fragment program if there's a GLSL vertex shader but no GLSL fragme...
authorBrian <brian.paul@tungstengraphics.com>
Tue, 2 Oct 2007 22:55:21 +0000 (16:55 -0600)
committerBrian <brian.paul@tungstengraphics.com>
Tue, 2 Oct 2007 22:55:21 +0000 (16:55 -0600)
This allows Glean glsl1 test to get pretty far.

src/mesa/main/texenvprogram.c

index cdf35b4..a554c03 100644 (file)
@@ -1247,7 +1247,8 @@ _mesa_UpdateTexEnvProgram( GLcontext *ctx )
 
    /* If a conventional fragment program/shader isn't in effect... */
    if (!ctx->FragmentProgram._Enabled &&
-       !ctx->Shader.CurrentProgram) {
+       (!ctx->Shader.CurrentProgram ||
+        !ctx->Shader.CurrentProgram->FragmentProgram) ) {
       make_state_key(ctx, &key);
       hash = hash_key(&key);