tcylindrical.c - plan9port - [fork] Plan 9 from user space
 (HTM) git clone git://src.adamsgaard.dk/plan9port
 (DIR) Log
 (DIR) Files
 (DIR) Refs
 (DIR) README
 (DIR) LICENSE
       ---
       tcylindrical.c (287B)
       ---
            1 #include <u.h>
            2 #include <libc.h>
            3 #include "map.h"
            4 
            5 int
            6 Xcylindrical(struct place *place, double *x, double *y)
            7 {
            8         if(fabs(place->nlat.l) > 80.*RAD)
            9                 return(-1);
           10         *x = - place->wlon.l;
           11         *y = place->nlat.s / place->nlat.c;
           12         return(1);
           13 }
           14 
           15 proj
           16 cylindrical(void)
           17 {
           18         return(Xcylindrical);
           19 }