/*
 *  geoloc.h
 *
 *	This file contains structure definitions for the geoloc type.
 *
 *	$Header: /private/mao/sequoia/retreat/RCS/geoloc.h,v 1.3 1993/02/14 01:12:06 mao Exp $
 */

/*
 *  GEOLOC -- internal representation for georeferenced coordinates.
 *
 *	This is a variable-length structure, since different projections
 *	require different amounts of state in the state entry at the end
 *	of the structure.  The name entry is a foreign key into the
 *	GEO_UNITS table, which contains a bunch of regprocs that we
 *	dispatch in order to do useful work.  Precision, x, and y
 *	values are interpreted with respect to the named coordinate
 *	system, but we assume that four-byte floats will be sufficient
 *	to store these in all cases.
 *
 *	All of the geoloc types begin with this much stuff.  Some of
 *	them have more stuff afterwards.
 */

typedef struct _GEOLOC {
	int	geo_varlen;
	char	geo_name[8];
	float	geo_prec;
	double	geo_x;
	double	geo_y;
} GEOLOC;

/*
 *  LAZEA -- Lambert Azimuthal Equal-Area projection
 */

typedef struct _LAZEA {
	GEOLOC	la_g;
	uint8	la_sphcode;
	double	la_lon0;
	double	la_lat0;
	double	la_falseE;
	double	la_falseN;
} LAZEA;

/*
 *  UTM -- Universal Transverse Mercator projection
 */

typedef struct _UTM {
	GEOLOC	utm_g;
	uint8	utm_sphcode;
	uint8	utm_zone;
} UTM;
