The glsl120 const array code fails, even though spec suggests it shouldn't. trunk
authorRyan C. Gordon <icculus@icculus.org>
Sun, 29 Jun 2008 02:00:46 -0400
branchtrunk
changeset 414 fdb12120213e
parent 413 618b677f4581
child 415 25ca83d8bbd5
The glsl120 const array code fails, even though spec suggests it shouldn't.
mojoshader.c
--- a/mojoshader.c	Sun Jun 29 02:00:08 2008 -0400
+++ b/mojoshader.c	Sun Jun 29 02:00:46 2008 -0400
@@ -2333,6 +2333,9 @@
     const int origscratch = ctx->scratchidx;
     int i;
 
+#if 0
+    // !!! FIXME: fails on Nvidia's and Apple's GL, even with #version 120.
+    // !!! FIXME:  (the 1.20 spec says it should work, though, I think...)
     if (ctx->support_glsl120)
     {
         // GLSL 1.20 can do constant arrays.
@@ -2368,6 +2371,7 @@
     } // if
 
     else
+#endif
     {
         // stock GLSL 1.0 can't do constant arrays, so make a global array
         //  and assign all entries at the start of the mainline...