Hello,

   The gtkglarea-sharp has a typo in its configure.ac script that causes
the gapi pkg-config check to fail. Also, examples fail to build with the
current Tao.OpenGl bindings due to API changes (bugfixes).

   The attached two patches allows gtkglarea-sharp to build (and run)
properly.

Regards,
-- 
Sam.
Index: examples/shapes/Teapot.cs
===================================================================
--- examples/shapes/Teapot.cs	(revision 88350)
+++ examples/shapes/Teapot.cs	(working copy)
@@ -78,12 +78,13 @@
 		      {0.84, -1.5, 0.075}
 		    };
 
-		  static float[,,] tex =
+		  static float[/*2*2*2*/] tex =
 		    {
-		      { {0, 0},
-			{1, 0}},
-		      { {0, 1},
-			{1, 1}}
+			0, 0,
+			1, 0,
+
+			0, 1,
+			1, 1
 		    };
 
 		  /* *INDENT-ON* */
@@ -155,7 +156,7 @@
 			    	  			}    	  			
 		    	  	}
 		    	  			
-		    		gl.glMap2f(gl.GL_MAP2_TEXTURE_COORD_2, 0, 1, 2, 2, 0, 1, 4, 2, tex[0,0,0]);
+		    		gl.glMap2f(gl.GL_MAP2_TEXTURE_COORD_2, 0, 1, 2, 2, 0, 1, 4, 2, tex);
 		    		gl.glMap2f(gl.GL_MAP2_VERTEX_3, 0, 1, 3, 4, 0, 1, 12, 4, cachedP[i]);
 		    		gl.glMapGrid2f(grid, 0.0f, 1.0f, grid, 0.0f, 1.0f);
 		    		gl.glEvalMesh2(type, 0, grid, 0, grid);
Index: examples/pick-object/PickWidget.cs
===================================================================
--- examples/pick-object/PickWidget.cs	(revision 88350)
+++ examples/pick-object/PickWidget.cs	(working copy)
@@ -90,13 +90,13 @@
 		}
 		
 		struct hitStruct {
-			public uint numNames;
+			public int numNames;
 			public double minZ;
 			public double maxZ;
-			public uint[] nameStack;
+			public int[] nameStack;
 		}
 
-		void processHits (int hits, uint[] buffer)
+		void processHits (int hits, int[] buffer)
 		{
 			uint i, j=0;
 			uint names, minZ, maxZ, numberOfNames;
@@ -115,7 +115,7 @@
 				// Console.WriteLine("Hit occured between [{0} .. {1}]", hit.minZ, hit.maxZ);
 				
 				// Allocate some space for our hit names
-				hit.nameStack = new uint[hit.numNames];
+				hit.nameStack = new int[hit.numNames];
 				
 				for(int k = 0; k < hit.numNames; k++){
 					hit.nameStack[k] = buffer[j++];
@@ -177,7 +177,7 @@
 				}
 				
 				// Establish a buffer for selection mode values
-				uint[] selectBuf = new uint[64];
+				int[] selectBuf = new int[64];
 				// http://www.mevis.de/opengl/glSelectBuffer.html
 				gl.glSelectBuffer (64, selectBuf);
 				
@@ -238,4 +238,4 @@
 		}	    
 	    
 	}
-}
\ No newline at end of file
+}
Index: examples/rotate-buttons/OldTeapot.cs
===================================================================
--- examples/rotate-buttons/OldTeapot.cs	(revision 88350)
+++ examples/rotate-buttons/OldTeapot.cs	(working copy)
@@ -78,12 +78,13 @@
 		      {0.84, -1.5, 0.075}
 		    };
 
-		  static float[,,] tex =
+		  static float[/*2*2*2*/] tex =
 		    {
-		      { {0, 0},
-			{1, 0}},
-		      { {0, 1},
-			{1, 1}}
+			0, 0,
+			1, 0,
+
+			0, 1,
+			1, 1
 		    };
 
 		  /* *INDENT-ON* */
@@ -155,7 +156,7 @@
 			    	  			}    	  			
 		    	  	}
 		    	  			
-		    		gl.glMap2f(gl.GL_MAP2_TEXTURE_COORD_2, 0, 1, 2, 2, 0, 1, 4, 2, tex[0,0,0]);
+		    		gl.glMap2f(gl.GL_MAP2_TEXTURE_COORD_2, 0, 1, 2, 2, 0, 1, 4, 2, tex);
 		    		gl.glMap2f(gl.GL_MAP2_VERTEX_3, 0, 1, 3, 4, 0, 1, 12, 4, cachedP[i]);
 		    		gl.glMapGrid2f(grid, 0.0f, 1.0f, grid, 0.0f, 1.0f);
 		    		gl.glEvalMesh2(type, 0, grid, 0, grid);
Index: configure.ac
===================================================================
--- configure.ac	(revision 88350)
+++ configure.ac	(working copy)
@@ -146,7 +146,7 @@
 dnl Find GAPI
 GAPI_REQUIRED_VERSION=1.9.0
 PKG_CHECK_MODULES(GAPI_DEPENDENCY,
-                  gapi-2.0 >= GAPI_REQUIRED_VERSION,
+                  gapi-2.0 >= $GAPI_REQUIRED_VERSION,
 		  enable_gapi=yes,
 		  enable_gapi=no
 		  )
_______________________________________________
Gtk-sharp-list maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/gtk-sharp-list

Reply via email to