summaryrefslogtreecommitdiffstats
path: root/src/mesa/main
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2009-03-19 10:25:24 -0600
committerBrian Paul <[email protected]>2009-03-19 10:29:13 -0600
commit65fc2ca82a38bc00ae4223124932af6771765041 (patch)
tree07d7a4b23f2e2d86af8131970df47780aa7f040a /src/mesa/main
parenta57d7edf069d1d161a45825021a7cf4d825fb88f (diff)
glsl: change GLSL #pragma initialization
Initialize the shader's pragma settings before calling the compiler. Added pragma "Ignore" fields to allow overriding the #pragma directives found in shader source code.
Diffstat (limited to 'src/mesa/main')
-rw-r--r--src/mesa/main/mtypes.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/mesa/main/mtypes.h b/src/mesa/main/mtypes.h
index 39138285338..52930094545 100644
--- a/src/mesa/main/mtypes.h
+++ b/src/mesa/main/mtypes.h
@@ -1956,6 +1956,8 @@ struct gl_query_state
/** Set by #pragma directives */
struct gl_sl_pragmas
{
+ GLboolean IgnoreOptimize; /**< ignore #pragma optimize(on/off) ? */
+ GLboolean IgnoreDebug; /**< ignore #pragma debug(on/off) ? */
GLboolean Optimize; /**< defaults on */
GLboolean Debug; /**< defaults off */
};
@@ -2026,6 +2028,7 @@ struct gl_shader_state
GLboolean EmitComments; /**< Annotated instructions */
void *MemPool;
GLbitfield Flags; /**< Mask of GLSL_x flags */
+ struct gl_sl_pragmas DefaultPragmas; /**< Default #pragma settings */
};