[Xastir] SDTS to shapefile conversion?

Jason Winningham jdw at eng.uah.edu
Mon Jan 3 17:25:13 EST 2005


On Jan 3, 2005, at 3:39 PM, Curt, WE7U wrote:

> I think people might be interested in those Shapefiles.  I might
> switch to Shapefiles as well for my topo lines.
>
> Get the dbfawk file to where it's useful to you and it'll be useful
> to others as well.

I should have supplied more detail with that last message.

First, I have experimented with exactly one 1:24k hypsography data set,  
so this may not work out as well as I think.

The ogr2ogr went effortlessly once Tom gave me a command line to cut  
and paste.  It created a set of 6 shapefiles, plus 3 other .dbf files  
with no associated shapefile.

The contours are in LE01 with the elevation information and some other  
data.  Most of the contours are also in another file.  Other shapefiles  
are points, consisting of data points at the edge of the area where  
contour lines end.  One seems to be nothing more than the 4 corner  
points.  Another is high and low points (e.g., mountain tops and  
sinkhole bottoms).

With a very simple dbfawk to draw labels and change the color the  
resulting map looks pretty much like the display of native SDTS data,  
except:

- most of the labels are only drawn at the map edges, i.e., when a  
contour line runs off the map.

- there is a line outlining the map; the area is in a rectangular box.  
SAR types may like this, as they know when they're switching quads.  I  
don't; I'd prefer a smoother transition.

The directory with the SDTS data set is 3.6Mb; the directory with the  
shapefiles is 15.4Mb.

  I couldn't find the quad name in any data file.  It may not have been  
in the SDTS data to begin with.

The dbfawk I've got under development for the contour file PC01 is:

BEGIN {
dbfinfo="RCID:SNID:ENID:ENTITY_LAB:SUPPLEMENT:AMENDED:APPROXIMAT: 
DEPRESSION:GLACIER_OR:UNDERWATER:BEST_ESTIM:SPOT_CATEG:PHOTOREVIS:RISE: 
FILL:ELEVATION";

dbffields="RCID:SNID:ENID:ENTITY_LAB:SUPPLEMENT:AMENDED:APPROXIMAT: 
DEPRESSION:GLACIER_OR:UNDERWATER:BEST_ESTIM:SPOT_CATEG:PHOTOREVIS:RISE: 
FILL:ELEVATION"}

BEGIN_RECORD {key=""; lanes=1; color=14; fill_color=14; label_color=14;  
name=""; filled=0; pattern=0; display_level=262144; label_level=262144;  
symbol=""; font_size=2}

/ELEVATION=[0.]*$/ {name="";next;}
/ELEVATION=([^.]*)/ {name="$1";}

-Jason
kg4wsv




More information about the Xastir mailing list