[mapserver-users] Shapefile Modification

woodbri at swoodbridge.com woodbri at swoodbridge.com
Mon Nov 4 18:46:49 EST 2002


Keith,

That would be one way to do it, but another would be to turn off the 
NA vmap0 data when you zoom to a certain scale and turn on the tiger 
data at the same scale.

-Steve W.

On 4 Nov 2002 at 16:09, Keith Baker wrote:

> I was thinking about doing this with the perl shapelib bindings if I
> couldn't find anyone with a tool.  Its a pretty simple task which
> would make a great utility.
> 
> Say I have shapefile with polygons (the us for example)
> 
> Then I have another shapefile which has a bunch of lines. (say from
> all of north america)
> 
> I want to remove all lines within the polygons (US), (ideally) trim
> the lines crossing the boundry, keep others...
> 
> Here is my issue...  I have all of vmap0 in shapefile.  I want to trim
> out the US data that I have duplicated from tiger data.  (roads,
> lakes, etc)
> 
> What do you think?
> 
> On Mon, 2002-11-04 at 15:55, Frank Warmerdam wrote:
> > Keith Baker wrote:
> > > Humm...  All suggestions turned out negitive.
> > > 
> > > ogr2ogr can remove things based on extent, but not based on
> > > another shapefile.  I may go hack away at it...  not sure yet. 
> > > Seems like something someone must have done.  I don't want to have
> > > to purchase ArcView for this project if I can avoid it.
> > 
> > Keith,
> > 
> > I have been developing Python bindings for OGR.  If you are willing
> > to put up with some hassles, we could look at doing your
> > filtering/changes as a python script using OGR.  I have only been
> > skimming this thread so you might need to repeat to me what you are
> > wanting to do, but in general an aweful lot should be possible with
> > OGR/Python.
> > 
> > Best regards,
> > 
> > -- 
> > ---------------------------------------+----------------------------
> > ---------- I set the clouds in motion - turn up   | Frank Warmerdam,
> > warmerdam at pobox.com light and sound - activate the windows |
> > http://pobox.com/~warmerdam and watch the world go round - Rush    |
> > Geospatial Programmer for Rent
> > 
> > 
> > 
> 
> 





More information about the mapserver-users mailing list