Hello Dane,

thanks for your hints.

> The OGR driver may be able to read directly from the csv:
> http://www.gdal.org/ogr/drv_csv.html

I wrote the script to convert the data to be "on the safe side", the CSV data
looked really wewird to me because it contained actual "\0" in the file.
(Actually, the script that i wrote also copied them, i just fixed that).

> Are you sure the data are points not lines?
> Maybe you should stick a LineSymbolizer in there just to be safe?

Thanks for that hint, i just changed it:

<Style name="qwetrack">
    <Rule>
      <MinScaleDenominator>50</MinScaleDenominator>
      <MaxScaleDenominator>5000000000000</MaxScaleDenominator>
      <LineSymbolizer>
        <CssParameter name="stroke">purple</CssParameter>
        <CssParameter name="stroke-width">7</CssParameter>
        <CssParameter name="stroke-opacity">1.0</CssParameter>
      </LineSymbolizer>
    </Rule>
</Style>

> This *should* be throwing an error because you have not provided a
> 'layer' parameter for the OGR plugin.
>
> See: http://trac.mapnik.org/wiki/OGR#Usage

Thanks again, i use it like this now:

<Layer name="track" status="on" srs="+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 +nadgri...@null 
+no_defs +over">
    <StyleName>qwetrack</StyleName>
    <Datasource>
      <Parameter name="type">ogr</Parameter>
      <Parameter name="base">/local/mapnik/</Parameter>
      <Parameter name="file">track.gpx</Parameter>
      <Parameter name="layer">waypoints</Parameter>
    </Datasource>
</Layer>

>
> > But i don't get no error
>
> That is surprising.
>
> > and i don't see the track.
>
> That is not! :)

Hmm, i still don't get no error and still don't see no track.  I actually
commented out all other layers to not miss anything, i only get blue
background.
I also changed the the part to render to (-180, -89, 180, 89) to not
miss anything.


> Maybe you should try getting the ogr driver working with some sample
> GPX data first that you know is valid, then try again with your
> converted csv?

My GPX file looks ok to me and i can also read it using gpsbabel:

$ gpsbabel -i gpx -f track.gpx -o text -F track.txt
$ head track.txt
-----------------------------------------------------------------------------
WPT001                       N48 55.109 E8 58.169 (32U 497765 5418395) alt:12

-----------------------------------------------------------------------------
WPT002                       N48 55.110 E8 58.170 (32U 497766 5418396) alt:22

-----------------------------------------------------------------------------
WPT003                       N48 55.110 E8 58.171 (32U 497767 5418397) alt:36

-----------------------------------------------------------------------------

$ gpsbabel -i gpx -f track.gpx -o gpx -F track2.gpx
$ head -n 30 track2.gpx
<?xml version="1.0" encoding="UTF-8"?>
<gpx
 version="1.0"
creator="GPSBabel - http://www.gpsbabel.org";
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
xmlns="http://www.topografix.com/GPX/1/0";
xsi:schemaLocation="http://www.topografix.com/GPX/1/1 
http://www.topografix.com/GPX/1/1/gpx.xsd";>
<time>2009-08-11T07:42:14Z</time>
<bounds minlat="48.918464000" minlon="8.969490000" maxlat="48.942979000" 
maxlon="9.065601000"/>
<wpt lat="48.918491000" lon="8.969490000">
  <ele>12.000000</ele>
  <name>WPT001</name>
  <cmt>WPT001</cmt>
  <desc>WPT001</desc>
</wpt>
<wpt lat="48.918501000" lon="8.969501000">
  <ele>22.000000</ele>
  <name>WPT002</name>
  <cmt>WPT002</cmt>
  <desc>WPT002</desc>
</wpt>
<wpt lat="48.918504000" lon="8.969524000">
  <ele>36.000000</ele>
  <name>WPT003</name>
  <cmt>WPT003</cmt>
  <desc>WPT003</desc>
</wpt>
<wpt lat="48.918464000" lon="8.969554000">
  <ele>54.000000</ele>
  <name>WPT004</name>

I don't understand that why nothing is rendered.

Has anybody got a sample GPX for me to try?

Has anybody got a sample osm.xml file to try (just to make sure)?

Has anybody got another hint?


Best regards,
Torsten.

_______________________________________________
Mapnik-users mailing list
[email protected]
https://lists.berlios.de/mailman/listinfo/mapnik-users

Reply via email to