[GRASS-SVN] r45810 - grass/branches/develbranch_6/display/d.grid
svn_grass at osgeo.org
svn_grass at osgeo.org
Wed Mar 30 01:22:10 EDT 2011
Author: hamish
Date: 2011-03-29 22:22:09 -0700 (Tue, 29 Mar 2011)
New Revision: 45810
Modified:
grass/branches/develbranch_6/display/d.grid/plot.c
Log:
placeholder code for geogrid marks
Modified: grass/branches/develbranch_6/display/d.grid/plot.c
===================================================================
--- grass/branches/develbranch_6/display/d.grid/plot.c 2011-03-30 05:09:00 UTC (rev 45809)
+++ grass/branches/develbranch_6/display/d.grid/plot.c 2011-03-30 05:22:09 UTC (rev 45810)
@@ -217,7 +217,10 @@
if (line_width)
D_line_width(line_width);
- G_plot_line(e1, n1, e2, n2);
+
+ if (mark_type == MARK_GRID)
+ G_plot_line(e1, n1, e2, n2);
+
D_line_width(0);
}
@@ -273,7 +276,10 @@
if (line_width)
D_line_width(line_width);
- G_plot_line(e1, n1, e2, n2);
+
+ if (mark_type == MARK_GRID)
+ G_plot_line(e1, n1, e2, n2);
+
D_line_width(0);
}
if (do_text) {
@@ -291,6 +297,31 @@
R_text_rotation(0.0); /* reset */
+ /* draw marks not grid lines */
+ if (mark_type != MARK_GRID) {
+ G_warning("Geogrid marks not yet implemented");
+#ifdef TODO
+ e1 = combine above;
+ n1 = combine above;
+
+ /* plot marks */
+ while (e1 <= window.east) {
+ n1 = y0; /* reset */
+ while (n1 <= window.north) {
+ if (mark_type == MARK_CROSS)
+ plot_cross(e1, n1, gcolor, 0.0);
+ else if (mark_type == MARK_FIDUCIAL)
+ plot_fiducial(e1, n1, gcolor, 0.0);
+ else if (mark_type == MARK_DOT)
+ plot_dot(e1, n1, gcolor);
+ n1 += grid_size;
+ }
+ e1 += grid_size;
+ }
+#endif
+ /* also TODO: rotate cross and fiducial marks by the converge angle; see g.region -n */
+ }
+
return 0;
}
More information about the grass-commit
mailing list