xref: /plan9-contrib/sys/src/cmd/map/libmap/rectangular.c (revision 219b2ee8daee37f4aad58d63f21287faa8e4ffdc)
1 #include "map.h"
2 
3 static double scale;
4 
5 static int
6 Xrectangular(struct place *place, double *x, double *y)
7 {
8 	*x = -scale*place->wlon.l;
9 	*y = place->nlat.l;
10 	return(1);
11 }
12 
13 proj
14 rectangular(double par)
15 {
16 	scale = cos(par*RAD);
17 	if(scale<.1)
18 		return 0;
19 	return(Xrectangular);
20 }
21