GPS4Palm

Source Code Documentation


georef.h File Reference

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Defines

#define GEOREF_SECTION   __attribute__ ((section ("geo")))

Functions

Boolean georef_filename (const Char *filename, double *map_lat, double *map_lon, UInt32 *map_scale) GEOREF_SECTION
 Get the map parameters SCALE, LAT and LON from the filename.
Boolean search_map (char *filename, UInt32 *card, double lon, double lat, UInt16 maxx, UInt16 maxy) GEOREF_SECTION
 Search for usable map.


Define Documentation

#define GEOREF_SECTION   __attribute__ ((section ("geo")))
 

Definition at line 49 of file georef.h.


Function Documentation

Boolean georef_filename const Char *  filename,
double *  map_lat,
double *  map_lon,
UInt32 *  map_scale
 

Get the map parameters SCALE, LAT and LON from the filename.

Parameters:
filename filename
map_lat Ptr to Latitude
map_lon Ptr to Longitude
map_scale Ptr to Scale
Returns:
true if all parameters decoded successfully, otherwise false map_lat, map_lon, and map_scale

Definition at line 90 of file georef.c.

References lat, and lon.

Referenced by MapFormHandleEvent(), and search_map().

Boolean search_map char *  filename,
UInt32 *  card,
double  lon,
double  lat,
UInt16  maxx,
UInt16  maxy
 

Search for usable map.

Note:
Currently search_map stops on the first map which fits, even if there is a better map (i.e. with the map center closer to the current position) available.
Parameters:
filename filename or NULL (returned by reference)
card card/volume number and VFS flag (returned by reference)
lat Latitude of current position
lon Longitude of current position
maxx Max. x-extent of screen
maxy Max. y-extent of screen
Returns:
true if usable map found, otherwise false

Definition at line 247 of file georef.c.

References calcxy(), CreateDatabase(), CROSS_X, CROSS_Y, DestroyDatabase(), fclose(), FILEDIR, fopen(), georef_filename(), getdir(), getdir_vfs(), gPrefs, gVfsManagerFtr, h, imginfo(), PrefsType::mapprefs, memcpy(), MapPrefsType::scale, scratch, SORTPREFIX, StrCopy, and w.

Referenced by MapFormHandleEvent().


Created: Mon, 08 Oct 2007 22:33:16 +0200
Copyright ©2004 M. Prinke