aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/mesa/shader/slang/slang_label.h
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2009-10-08 13:15:52 +0000
committermarha <marha@users.sourceforge.net>2009-10-08 13:15:52 +0000
commita0c4815433ccd57322f4f7703ca35e9ccfa59250 (patch)
treef5213802ec12adb86ec3136001c1c29fe5343700 /mesalib/src/mesa/shader/slang/slang_label.h
parentc73dc01b6de45612b24dc2dd34fba24d81ebf46c (diff)
downloadvcxsrv-a0c4815433ccd57322f4f7703ca35e9ccfa59250.tar.gz
vcxsrv-a0c4815433ccd57322f4f7703ca35e9ccfa59250.tar.bz2
vcxsrv-a0c4815433ccd57322f4f7703ca35e9ccfa59250.zip
Added MesaLib-7.6
Diffstat (limited to 'mesalib/src/mesa/shader/slang/slang_label.h')
-rw-r--r--mesalib/src/mesa/shader/slang/slang_label.h45
1 files changed, 45 insertions, 0 deletions
diff --git a/mesalib/src/mesa/shader/slang/slang_label.h b/mesalib/src/mesa/shader/slang/slang_label.h
new file mode 100644
index 000000000..87068ae7a
--- /dev/null
+++ b/mesalib/src/mesa/shader/slang/slang_label.h
@@ -0,0 +1,45 @@
+#ifndef SLANG_LABEL_H
+#define SLANG_LABEL_H 1
+
+#include "main/imports.h"
+#include "main/mtypes.h"
+#include "shader/prog_instruction.h"
+
+
+struct slang_label_
+{
+ char *Name;
+ GLint Location;
+ /**
+ * List of instruction references (numbered starting at zero) which need
+ * their BranchTarget field filled in with the location eventually
+ * assigned to the label.
+ */
+ GLuint NumReferences;
+ GLuint *References; /** Array [NumReferences] */
+};
+
+typedef struct slang_label_ slang_label;
+
+
+extern slang_label *
+_slang_label_new(const char *name);
+
+extern slang_label *
+_slang_label_new_unique(const char *name);
+
+extern void
+_slang_label_delete(slang_label *l);
+
+extern void
+_slang_label_add_reference(slang_label *l, GLuint inst);
+
+extern GLint
+_slang_label_get_location(const slang_label *l);
+
+extern void
+_slang_label_set_location(slang_label *l, GLint location,
+ struct gl_program *prog);
+
+
+#endif /* SLANG_LABEL_H */