[GRASS-user] Re: import a folder full of shapefiles and reproject on-the-fly?

Tim Michelsen timmichelsen at gmx-topmail.de
Wed Jul 30 10:58:59 EDT 2008


> > * I cannot just point the program to a directory of shapefiles and tell
> >   it import all. QGIS, gvSIG and ArcGIS can do this.
> 
> We could easily add v.in.ogr.all or v.external.all, I suppose two or
> three lines of shell script :) Could be stored in the Addons wiki.
I added the script from Paolo/Perrygeo
1.35.1 Shapemerge -
5.1.35.1 Shapemerge - http://grass.osgeo.org/wiki/GRASS_AddOns
#Shapemerge
But I would like to see this integraded into GRASS...

> I don't agree. You can easily import and reproject single maps even
> with the various d.m/gis.m/wxpython user interfaces:
> - create new location *graphically* from startup menu, now even with
>   location wizard.
> - run r/v.proj
What if you receive a location with 5 vectors and 10 rasters?
Since we are agreeing that GRASS has a strong script support one
could to something like this pseudo code:

### create_new_projected_location
grass_command_to_create_newlocation \
currentlocation_new_epsg_code 'EPSG:XXXX'
grass_command_enter_to_currentlocation_new_epsg_code
## in the new location:
for vect in currentlocation:
    v.proj in=vect out=vect location=currentlocation
for rast in currentlocation:
    r.proj ...
print "Please exit GRASS and enter the new reprojetced location
'currentlocation_new_epsg_code'."

I don't know if this is possible with grass scripting but would ease up
changing the projection.

> see
> http://grass.osgeo.org/wiki/WxPython-based_GUI_for_GRASS
#Cartography_tools
> -> work in progress
Nice.
But please consider to assist the user in adjusting the g.region before
printing. My ps.map.def that I tested on spearfish doesn't work when
trying to print a raster of whole Europe. It results in a 4GB PS file although
I'd set the paper size.

Regards,
Timmie



More information about the grass-user mailing list