Hi all!
I am rasterizing a huge amount of shp-data with geoserver wms. There are two datasets; one which includes the whole area and another one including the areas which will be excluded in the final product. So the outcome should be a set of rasters made from shape-set1 but having "holes" in the areas defined in shape-set2. Ok?
Any idea what would be the cleverest, the most powerful way to get it done?
Should I load it all into PostGIS? (I am not yet familiar with it and I can't claim to be any expert in wfs either.) But on the other hand, I have read it to be much more powerful than using shapes.
BTW: Not a geoserver question, but are there any batch processing system for loading shapes into PostGIS? I have about 400 shapes...
reg. mika
Lehtonen, Mika ha scritto:
Hi all!
I am rasterizing a huge amount of shp-data with geoserver wms. There are two datasets; one which includes the whole area and another one including the areas which will be excluded in the final product. So the outcome should be a set of rasters made from shape-set1 but having "holes" in the areas defined in shape-set2. Ok?
Ok depends on how you want the holes to be depicted. If it's ok to treat
them like most military zones are in common maps, that is, with the poligon with a solid fill in it (and a "fire here" label on top of it...
kidding), then making a WMS request with the two layers one on top
of the other should be fine.
If instead you need to make the holes really transparent, then no, you'll have to make some polygon cookie cutter with postgis.
Any idea what would be the cleverest, the most powerful way to get it done?
More powerful == fastest? In this case yes, shapefiles are faster if you're extracting huge amounts of data, just as fast as postgis.
Should I load it all into PostGIS? (I am not yet familiar with it and I can't claim to be any expert in wfs either.) But on the other hand, I have read it to be much more powerful than using shapes.
BTW: Not a geoserver question, but are there any batch processing system for loading shapes into PostGIS? I have about 400 shapes...
A script from command line calling
shp2pgsql -s mySrs -I name.shp name | pgsql blah
for each file should be fine.... thought... good look configuring manually the 400 shapes in GeoServer (see the other threads about mass
loading data into GeoServer).
Cheers
Andrea
Andrea,
I am a little confused of this. I am currently testing this issue. Unfortunately, I do not have two files, but three; one with lines, one with texts and one polygon mask. So I loaded them into gs and wrote an html which uses OpenLayers.js. The mask covers the line layer nicely but not the texts! How the peep I could get rid of the texts in the mask areas? There should be absolutely nothing in the masked areas.
mika
Andrea Aime kirjoitti:
Lehtonen, Mika ha scritto:
Hi all!
I am rasterizing a huge amount of shp-data with geoserver wms. There are two datasets; one which includes the whole area and another one including the areas which will be excluded in the final product. So the outcome should be a set of rasters made from shape-set1 but having "holes" in the areas defined in shape-set2. Ok?
Ok depends on how you want the holes to be depicted. If it's ok to treat
them like most military zones are in common maps, that is, with the poligon with a solid fill in it (and a "fire here" label on top of it...
kidding), then making a WMS request with the two layers one on top
of the other should be fine.
If instead you need to make the holes really transparent, then no, you'll have to make some polygon cookie cutter with postgis.
Any idea what would be the cleverest, the most powerful way to get it done?
More powerful == fastest? In this case yes, shapefiles are faster if you're extracting huge amounts of data, just as fast as postgis.
Should I load it all into PostGIS? (I am not yet familiar with it and I can't claim to be any expert in wfs either.) But on the other hand, I have read it to be much more powerful than using shapes.
BTW: Not a geoserver question, but are there any batch processing system for loading shapes into PostGIS? I have about 400 shapes...
A script from command line calling
shp2pgsql -s mySrs -I name.shp name | pgsql blah
for each file should be fine.... thought... good look configuring manually the 400 shapes in GeoServer (see the other threads about mass
loading data into GeoServer).
Cheers
Andrea
Lehtonen, Mika ha scritto:
Andrea,
I am a little confused of this. I am currently testing this issue. Unfortunately, I do not have two files, but three; one with lines, one with texts and one polygon mask. So I loaded them into gs and wrote an html which uses OpenLayers.js. The mask covers the line layer nicely but not the texts! How the peep I could get rid of the texts in the mask areas? There should be absolutely nothing in the masked areas.
Ah, you're out of luck then, there is not way to make labels disappear,
they always end up on the top of the map.
To get what you want for good you'll have to do use postgis or
something else to delete all points that do fall within a mask polygon.
Cheers
Andrea