aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/shader/program_instruction.h
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2005-11-20 17:52:40 +0000
committerBrian Paul <[email protected]>2005-11-20 17:52:40 +0000
commite31ac052236ea615b4995f9ec301d8af4b864531 (patch)
tree5f0229e4a01b25078b710cbc4d288c0c37fc83c3 /src/mesa/shader/program_instruction.h
parent22db53577603afef8fdf62c324ff5977de76b9d8 (diff)
Make Saturate a 2-bit field again, renamed to SaturateMode with three
possible values: SATURATE_OFF, SATURATE_ZERO_ONE and SATURATE_PLUS_MINUS_ONE.
Diffstat (limited to 'src/mesa/shader/program_instruction.h')
-rw-r--r--src/mesa/shader/program_instruction.h19
1 files changed, 15 insertions, 4 deletions
diff --git a/src/mesa/shader/program_instruction.h b/src/mesa/shader/program_instruction.h
index a6910bd2f8b..20886d9f021 100644
--- a/src/mesa/shader/program_instruction.h
+++ b/src/mesa/shader/program_instruction.h
@@ -54,7 +54,7 @@
/*@}*/
-/*
+/**
* Instruction precision for GL_NV_fragment_program
*/
/*@{*/
@@ -65,6 +65,16 @@
/**
+ * Saturation modes when storing values.
+ */
+/*@{*/
+#define SATURATE_OFF 0
+#define SATURATE_ZERO_ONE 1
+#define SATURATE_PLUS_MINUS_ONE 2
+/*@}*/
+
+
+/**
* Program instruction opcodes, for both vertex and fragment programs.
* \note changes to this opcode list must be reflected in t_vb_arbprogram.c
*/
@@ -267,8 +277,8 @@ struct prog_instruction
* condition code register that is to be updated.
*
* In GL_NV_fragment_program or GL_NV_vertex_program2 mode, only condition
- * code register 0 is available. In GL_NV_vertex_program3 mode, condition code registers
- * 0 and 1 are available.
+ * code register 0 is available. In GL_NV_vertex_program3 mode, condition
+ * code registers 0 and 1 are available.
*
* \since
* NV_fragment_program, NV_fragment_program_option, NV_vertex_program2,
@@ -280,11 +290,12 @@ struct prog_instruction
* Saturate each value of the vectored result to the range [0,1] or the
* range [-1,1]. \c SSAT mode (i.e., saturation to the range [-1,1]) is
* only available in NV_fragment_program2 mode.
+ * Value is one of the SATURATE_* tokens.
*
* \since
* NV_fragment_program, NV_fragment_program_option, NV_vertex_program3.
*/
- GLuint Saturate:1;
+ GLuint SaturateMode:2;
/**
* Per-instruction selectable precision.