laue.c (326B)
1 #include <u.h> 2 #include <libc.h> 3 #include "map.h" 4 5 6 static int 7 Xlaue(struct place *place, double *x, double *y) 8 { 9 double r; 10 if(place->nlat.l<PI/4+FUZZ) 11 return(-1); 12 r = tan(PI-2*place->nlat.l); 13 if(r>3) 14 return(-1); 15 *x = - r * place->wlon.s; 16 *y = - r * place->wlon.c; 17 return(1); 18 } 19 20 proj 21 laue(void) 22 { 23 return(Xlaue); 24 }