[GRASS-SVN] r53380 - grass/trunk/display/d.what.vect
svn_grass at osgeo.org
svn_grass at osgeo.org
Sat Oct 13 04:00:19 PDT 2012
Author: mmetz
Date: 2012-10-13 04:00:19 -0700 (Sat, 13 Oct 2012)
New Revision: 53380
Modified:
grass/trunk/display/d.what.vect/what.c
Log:
d.what.vect: adjust for new topology
Modified: grass/trunk/display/d.what.vect/what.c
===================================================================
--- grass/trunk/display/d.what.vect/what.c 2012-10-13 09:00:14 UTC (rev 53379)
+++ grass/trunk/display/d.what.vect/what.c 2012-10-13 11:00:19 UTC (rev 53380)
@@ -205,7 +205,10 @@
fprintf(stdout,
"-----------------------------------------------\n");
- Vect_get_line_areas(&(Map[i]), line, &left, &right);
+ if (type & GV_BOUNDARY)
+ Vect_get_line_areas(&(Map[i]), line, &left, &right);
+ else
+ left = right = 0;
fprintf(stdout,
_("Line: %d Type: %s Left: %d Right: %d "),
line, buf, left, right);
@@ -214,11 +217,12 @@
fprintf(stdout, _("Length: %f\n"), l);
}
else { /* points */
- nnodes = 1;
+ nnodes = 0;
fprintf(stdout, "\n");
}
- Vect_get_line_nodes(&(Map[i]), line, &node[0], &node[1]);
+ if (nnodes > 0)
+ Vect_get_line_nodes(&(Map[i]), line, &node[0], &node[1]);
for (n = 0; n < nnodes; n++) {
double nx, ny, nz;
More information about the grass-commit
mailing list