glsl: call the program optimizer

This still needs more testing bug glean and Mesa GLSL tests seem OK.
This commit is contained in:
Brian Paul
2009-03-06 15:45:01 -07:00
parent e60b3067d8
commit 0945b78244
+5
View File
@@ -32,6 +32,7 @@
#include "main/context.h"
#include "shader/program.h"
#include "shader/programopt.h"
#include "shader/prog_optimize.h"
#include "shader/prog_print.h"
#include "shader/prog_parameter.h"
#include "shader/grammar/grammar_mesa.h"
@@ -2796,6 +2797,10 @@ _slang_compile(GLcontext *ctx, struct gl_shader *shader)
shader->CompileStatus = success;
if (success) {
_mesa_optimize_program(ctx, shader->Program);
}
if (ctx->Shader.Flags & GLSL_LOG) {
_mesa_write_shader_to_file(shader);
}