proj2.c

Go to the documentation of this file.
00001 #include <grass/gis.h>
00002 #include <grass/glocale.h>
00003 
00004 int G__projection_units(int n)
00005 {
00006     switch (n)
00007     {
00008     case PROJECTION_XY:
00009         return 0;
00010     case PROJECTION_UTM:
00011         return METERS;
00012     case PROJECTION_SP:
00013         return FEET;
00014     case PROJECTION_LL:
00015         return DEGREES;
00016     default:
00017         return -1;
00018     }
00019 }
00020 
00021 char *G__unit_name (int unit,int plural)
00022 {
00023     switch (unit)
00024     {
00025     case 0:
00026         return plural ? "units" : "unit";
00027     case METERS:
00028         return plural ? "meters" : "meter";
00029     case FEET:
00030         return plural ? "feet" : "foot";
00031     case DEGREES:
00032         return plural ? "degrees" : "degree";
00033     default:
00034         return NULL;
00035     }
00036 }
00037 
00038 char *G__projection_name(int n)
00039 {
00040     switch (n)
00041     {
00042     case PROJECTION_XY:
00043         return "x,y";
00044     case PROJECTION_UTM:
00045         return "UTM";
00046     case PROJECTION_SP:
00047         return "State Plane";
00048     case PROJECTION_LL:
00049         return _("Latitude-Longitude");
00050     case PROJECTION_OTHER:
00051         return _("Other Projection");
00052     default:
00053         return NULL;
00054     }
00055 }

Generated on Wed Dec 19 14:59:06 2007 for GRASS by  doxygen 1.5.4