[GRASS-SVN] r48613 - grass/trunk/lib/nviz

svn_grass at osgeo.org svn_grass at osgeo.org
Tue Oct 4 05:25:36 EDT 2011


Author: martinl
Date: 2011-10-04 02:25:35 -0700 (Tue, 04 Oct 2011)
New Revision: 48613

Modified:
   grass/trunk/lib/nviz/draw.c
Log:
libnviz: texture support added annakrat


Modified: grass/trunk/lib/nviz/draw.c
===================================================================
--- grass/trunk/lib/nviz/draw.c	2011-10-03 22:03:10 UTC (rev 48612)
+++ grass/trunk/lib/nviz/draw.c	2011-10-04 09:25:35 UTC (rev 48613)
@@ -6,11 +6,12 @@
    Based on visualization/nviz/src/draw.c and
    visualization/nviz/src/togl_flythrough.c
    
-   (C) 2008, 2010 by the GRASS Development Team
+   (C) 2008, 2010-2011 by the GRASS Development Team
    This program is free software under the GNU General Public License
    (>=v2). Read the file COPYING that comes with GRASS for details.
 
    \author Updated/modified by Martin Landa <landa.martin gmail.com> (Google SoC 2008/2010)
+   \author Textures by Anna Kratochvilova 
  */
 
 #include <grass/nviz.h>
@@ -379,10 +380,14 @@
 
     glBegin(GL_QUADS);
 
-    glTexCoord2d(0.0,1.0);glVertex2d(x, y);
-    glTexCoord2d(0.0,0.0);glVertex2d(x, y + height);
-    glTexCoord2d(1.0,0.0);glVertex2d(x + width, y + height);
-    glTexCoord2d(1.0,1.0);glVertex2d(x + width, y);
+    glTexCoord2d(0.0,1.0);
+    glVertex2d(x, y);
+    glTexCoord2d(0.0,0.0);
+    glVertex2d(x, y + height);
+    glTexCoord2d(1.0,0.0);
+    glVertex2d(x + width, y + height);
+    glTexCoord2d(1.0,1.0);
+    glVertex2d(x + width, y);
 
     glEnd();
 



More information about the grass-commit mailing list