[Geomoose-users] print osm tiles

Brent Fraser bfraser at geoanalytic.com
Tue Feb 10 08:20:41 PST 2015


Geograefin,

   I just copied the "frmt_wms_openstreetmap_tms.xml" file into the same 
folder as the map file and it works fine..  I suspect you could put the 
full path to the xml file in the DATA object in the map file, but I have 
not tried it.

   Interestingly, the xml file (along with many others) are delivered 
with the GDAL source code, but not with the binary distributions I use.  
The files are:

frmt_wms_metacarta_tms.xml
frmt_wms_metacarta_wmsc.xml
frmt_wms_onearth_global_mosaic.xml
frmt_wms_openstreetmap_tms.xml
frmt_wms_tileservice_bmng.xml
frmt_wms_tileservice_nysdop2004.xml

I may have to try some of these!

Best Regards,
Brent Fraser

On 2/10/2015 8:42 AM, geo.graefin at web.de wrote:
>
> Hello Brent,
> I'm sorry to bother you again, but I could not find where to store the 
> xml file. How does the MapServer interact with GDAL? Where I have to 
> reference the xml file? Apparently the content of the xml file should 
> look like this one 
> [http://code.metager.de/source/xref/lib/gdal/frmts/wms/frmt_wms_openstreetmap_tms.xml].
> By these instructions [http://www.gdal.org/frmt_wms.html] I can not 
> look through.
> Thank you very much in advance for answering!
> Greetings, Geograefin
> *Gesendet:* Montag, 09. Februar 2015 um 16:38 Uhr
> *Von:* "Brent Fraser" <bfraser at geoanalytic.com>
> *An:* geo.graefin at web.de, "GeoMOOSE Users List" 
> <geomoose-users at lists.osgeo.org>
> *Betreff:* Re: Aw: Re: [Geomoose-users] print osm tiles
> Geograefin,
>
>   Check your "frmt_wms_openstreetmap_tms.xml" file is working by using 
> gdal_translate (or gdalinfo) command line program.
> Best Regards,
> Brent Fraser
> On 2/9/2015 7:31 AM, geo.graefin at web.de wrote:
>
>     Dear Brent Fraser,
>     in addition to the post you listed below, I have created a map
>     file (my_osm.map), to support the printing of osm tiles.
>     MAP
>      #--------------------------------------------------------------------------------
>      #---------------------------------MAPFILEHEADER----------------------------------
>      #--------------------------------------------------------------------------------
>         NAME 'background'
>         STATUS ON
>         DEBUG 5
>         CONFIG "MS_ERRORFILE" "/ms4w/tmp/ms_error.txt"
>         #EXTENT 1190889 6412149 1987057 6860988
>         #SIZE 100 100
>         #UNITS METERS
>         #IMAGETYPE PNG
>         PROJECTION
>             'init=epsg:3857'     #projection of the map
>         END
>         OUTPUTFORMAT
>             NAME png
>             DRIVER "GD/PNG"
>             MIMETYPE "image/png"
>             IMAGEMODE PC256
>             EXTENSION "png"
>         END
>         INCLUDE "../../geomoose_globals.map"
>      #--------------------------------------------------------------------------------
>      #-----------------------------------WEB-SECTION----------------------------------
>      #--------------------------------------------------------------------------------
>         WEB
>             IMAGEPATH "/ms4w/tmp/ms_tmp/"
>             IMAGEURL "/ms_tmp/"
>             METADATA
>                 WMS_TITLE "open street map"
>                 WMS_ABSTRACT "Open Street Map Kacheln"
>                 WMS_ONLINERESOURCE "http://localhost/cgi-bin/mapserv?
>      map=/geomoose2/maps/demo/test/angebote/my_osm.map"
>                 WMS_SRS "EPSG:3857"  #projection of the service
>                 WMS_ENABLE_REQUEST "*"
>             END
>         END
>      #--------------------------------------------------------------------------------
>      #-------------------------------------LAYER--------------------------------------
>      #--------------------------------------------------------------------------------
>           LAYER
>             NAME 'my_osm'
>             DATA "frmt_wms_openstreetmap_tms.xml"
>             STATUS ON
>             TYPE RASTER
>             PROCESSING "OVERSAMPLE_RATIO=1"
>             PROCESSING "LOAD_FULL_RES_IMAGE=NO"
>             UNITS METERS
>             METADATA
>                 WMS_TITLE "open street map tiles"
>             END
>             PROJECTION
>                 "proj=merc" "a=6378137" "b=6378137" "lat_ts=0.0"
>     "lon_0=0.0" "x_0=0.0" "y_0=0" "k=1.0" "units=m" "nadgrids=@null"
>     "no_defs"
>             END
>           END
>     END     #end map
>     Are the settings correct, the coordinate systems, too?
>     And the settings in mapbook.xml are these:
>         <map-source name="background" type="mapserver">
>      <file>./test/angebote/my_osm.map</file>
>             <layer name="my_osm" status="on"/>
>         </map-source>
>         <layer title="Mein OSM" src="background/my_osm" legend="false"
>     fade="false" unfade="false"/>
>     I would be very grateful if you could check this! Currently, there
>     is just a white display, when I turn on the layer.
>     Thank you very much!
>     Greetings, Geograefin
>     *Gesendet:* Mittwoch, 04. Februar 2015 um 18:56 Uhr
>     *Von:* "Brent Fraser" <bfraser at geoanalytic.com>
>     *An:* geo.graefin at web.de, geomoose-users at lists.osgeo.org
>     *Betreff:* Re: [Geomoose-users] print osm tiles
>     There's some info on a work-around:
>
>     http://osgeo-org.1560.x6.nabble.com/Geomoose-users-Printing-tt4928024.html
>
>     but the results are not very good.
>
>     Best Regards,
>     Brent Fraser
>
>     On 2/4/2015 3:45 AM, geo.graefin at web.de wrote:
>
>         Hello,
>         is there a current solution to print open street map tiles in
>         GeoMOOSE?
>         Thank you for your answers!
>         Greetings, Geograefin
>
>         _______________________________________________
>         Geomoose-users mailing list
>         Geomoose-users at lists.osgeo.org
>         http://lists.osgeo.org/mailman/listinfo/geomoose-users
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/geomoose-users/attachments/20150210/40ae41d9/attachment-0001.html>


More information about the Geomoose-users mailing list