[Openstreetmap] GPS point submission format

Petter Reinholdtsen pere at hungry.com
Tue Nov 9 23:55:23 GMT 2004

[Petter Reinholdtsen]
> Perhaps.  It also depend on the availability of useful libraries.  I'm
> currently investigating possible exchange formats, and the one I
> research at the moment, ArcView/ESRI Shapefile, have C libraries for
> reading and writing.
> The nice thing about this format is that it is supported by several
> GIS programs already (qgis and grass at least), so we get access to
> visualization tools without having to do anything more.

It was a good idea, but I was unable to get it to work.  (Well, I was
able to generate shapefiles and display them using qgis, but qgis
didn't seem to support files with 3D coordinates, only 2D coordinates,
so we would loose information or loose the ability to visualize the
information using at least qgis.  I'm not sure which other tools are
useful for this.  Anyone got a clue?

> Anyone here know which GIS formats are in common use?  Which one of
> these are capable of storing GPS points with accuracy info?  We
> probably also want it to store info on who collected the
> information, and perhaps some info on license.

I'm now looking at GPX, a XML based format for storing and exchanging
GPS data, and IGC data file format, a text based format for storing
flight information.  Anyone have any experience with any of these?

  GPX - GPS Exchange Format

  IGC data file format

Here is the program I used to test shapefile loading.  I tried with
different valies in infotype, and changed the value of vertexes to
match the format used.

#include <stdio.h>
#include <assert.h>
#include <shapefil.h>

int main()
  int count = 10;
  int i;
  int infotype = SHPT_ARCZ; /* SHPT_POINTZ */
  double x[10], y[10], z[10];
  SHPHandle handle = SHPCreate( "gpspoints.shp",  infotype );
  for (i = 0 ; i < count; ++i)
      SHPObject *object;
      int entity;
      int vertexes = 3;
      x[0] = i,     y[0] =  i    * 2, z[0] =  i    * 3;
      x[1] = i-0.5, y[1] = (i-1) * 2, z[1] = (i-1) * 3;
      x[2] = i-1,   y[2] = (i-1) * 2, z[2] = (i-1) * 3;

      object = SHPCreateSimpleObject(infotype, vertexes, &x[0], &y[0], &z[0]);
      entity = SHPWriteObject(handle, -1, object );

  return 0;

More information about the talk mailing list