[Xastir] GeoPDF

Derrick Brashear shadow at gmail.com
Tue Aug 30 22:49:59 EDT 2011


I know this came up a while ago.

The USGS has been making historic topos available online, free. My
entire state suddenly showed up, so I got interested. They're GeoPDF.
Last we discussed it here, no support. That's fine: GDAL 0.8.0 and on
supports it. You need poppler with xpdf support, and then you can just
run gdal_translate.
Better yet, if you want to crop them instead of letting xastir handle
the neatline, the neatline info is embedded and gdalwarp will help,
but you need 0.8.1 for -crop_to_cutline.

Assuming your map is $i, this works:

gdalinfo $i|grep NEATLINE | awk -F= '{print "foo,WKT\nbla,\"" $2
"\""}' > $i.csv;
gdalwarp -crop_to_cutline -cutline $i.csv  -co "GDAL_PDF_DPI=250" -of
GTiff  $i $i.tiff

Related-ish, if you just want to view these on an iPad, PDF Maps is
free and supports them, georeferencing included. Not helpful for APRS
tho.

-- 
Derrick



More information about the Xastir mailing list