[GRASS-SVN] r58456 - grass/trunk/misc/m.nviz.image

svn_grass at osgeo.org svn_grass at osgeo.org
Fri Dec 13 11:48:30 PST 2013


Author: annakrat
Date: 2013-12-13 11:48:30 -0800 (Fri, 13 Dec 2013)
New Revision: 58456

Modified:
   grass/trunk/misc/m.nviz.image/args.c
   grass/trunk/misc/m.nviz.image/local_proto.h
   grass/trunk/misc/m.nviz.image/volume.c
Log:
m.nviz.image: added flag to draw volume box

Modified: grass/trunk/misc/m.nviz.image/args.c
===================================================================
--- grass/trunk/misc/m.nviz.image/args.c	2013-12-13 12:10:17 UTC (rev 58455)
+++ grass/trunk/misc/m.nviz.image/args.c	2013-12-13 19:48:30 UTC (rev 58456)
@@ -706,6 +706,12 @@
 	_("Toggles normal direction of all isosurfaces (changes light effect)");
     params->isosurf_toggle_norm_dir->guisection = _("Volumes");
 
+    params->draw_volume_box = G_define_flag();
+    params->draw_volume_box->key = 'b';
+    params->draw_volume_box->description =
+	_("Draw volume box");
+    params->draw_volume_box->guisection = _("Volumes");
+
     /* slices */
     /* slice axis */
     params->slice = G_define_option();

Modified: grass/trunk/misc/m.nviz.image/local_proto.h
===================================================================
--- grass/trunk/misc/m.nviz.image/local_proto.h	2013-12-13 12:10:17 UTC (rev 58455)
+++ grass/trunk/misc/m.nviz.image/local_proto.h	2013-12-13 19:48:30 UTC (rev 58456)
@@ -8,6 +8,7 @@
 {
     struct Flag *mode_all;
     struct Flag *isosurf_toggle_norm_dir;
+    struct Flag *draw_volume_box;
 
     struct Option 
     /* surface */

Modified: grass/trunk/misc/m.nviz.image/volume.c
===================================================================
--- grass/trunk/misc/m.nviz.image/volume.c	2013-12-13 12:10:17 UTC (rev 58455)
+++ grass/trunk/misc/m.nviz.image/volume.c	2013-12-13 19:48:30 UTC (rev 58456)
@@ -61,6 +61,9 @@
 	}
     
 	GVL_set_trans(id, x, y, z);
+	if (params->draw_volume_box->answer) {
+	    GVL_set_draw_wire(id, 1);
+	}
     }
 
     return 1;



More information about the grass-commit mailing list