Explorar o código

r.water.outlet: Add title and history

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@68407 15284696-431f-4ddb-bdfa-cd5b030d7da7
Huidae Cho %!s(int64=9) %!d(string=hai) anos
pai
achega
fbf108012a
Modificáronse 1 ficheiros con 6 adicións e 0 borrados
  1. 6 0
      raster/r.water.outlet/main.c

+ 6 - 0
raster/r.water.outlet/main.c

@@ -48,6 +48,7 @@ int main(int argc, char *argv[])
     CELL *cell_buf;
     char drain_name[GNAME_MAX], basin_name[GNAME_MAX];
     struct Cell_head window;
+    struct History hist;
 
     G_gisinit(argv[0]);
 
@@ -129,5 +130,10 @@ int main(int argc, char *argv[])
     G_free(cell_buf);
     Rast_close(basin_fd);
 
+    Rast_put_cell_title(basin_name, "Watershed basin");
+    Rast_short_history(basin_name, "raster", &hist);
+    Rast_command_history(&hist);
+    Rast_write_history(basin_name, &hist);
+
     exit(EXIT_SUCCESS);
 }