On Wed, May 19, 2010 at 3:56 AM, Sander van Grieken <[email protected]> wrote:
> On Tuesday 18 May 2010 11:20:05 John Stowers wrote: > > Some work is ongoing here, API comments welcomed. > > > > http://github.com/nzjrs/osm-gps-map/tree/track-api-rework > > Ah you have created add/remove track functions, nice. I found that by using > the _replace > function I can simulate add/remove, but I will switch over to the new > functions once > there's a new release of OGM. > Yeah, the new API should be a little more consistent. * The map has an internal 'GPS track' (an OsmGpsMapTrack object). The _gps_add function/s operate on this track so that the library retains a simple API if you only want to draw one track * If you want to have multiple tracks then the new API will be something like OsmGpsMapTrack *t; t = osm_gps_map_track_new() osm_gps_map_track_set_color(something) osm_gps_map_add_track(map, track) ... void got_gps_data(float lat, float lon) { OsmGpsMapPoint p; osm_gps_map_point_from_degrees(&p, lat, lon) osm_gps_map_track_add_point(t, &p) } i.e. all track interaction can be done through the track object, and you don't need to call functions on the map object. > I just hooked up the OsmGpsMap defined maps into foxtrotGPS and I noticed > that setting the > map-source property does not redraw the map. It will use the new source > though when > forcing a redraw by using zoom in or out. > This is a bug. John > > grtz, > Sander > _______________________________________________ > This message is sent to you from [email protected] mailing list. > Visit http://lists.osgeo.org/mailman/listinfo/foss-gps to manage your > subscription > For more information, check http://wiki.osgeo.org/wiki/FOSS-GPS >
_______________________________________________ This message is sent to you from [email protected] mailing list. Visit http://lists.osgeo.org/mailman/listinfo/foss-gps to manage your subscription For more information, check http://wiki.osgeo.org/wiki/FOSS-GPS
