ogr_srs_api.h

Go to the documentation of this file.
00001 /******************************************************************************
00002  * $Id: ogr_srs_api.h,v 1.50 2005/02/17 16:34:17 fwarmerdam Exp $
00003  *
00004  * Project:  OpenGIS Simple Features Reference Implementation
00005  * Purpose:  C API and constant declarations for OGR Spatial References.
00006  * Author:   Frank Warmerdam, warmerda@home.com
00007  *
00008  ******************************************************************************
00009  * Copyright (c) 2000, Frank Warmerdam
00010  *
00011  * Permission is hereby granted, free of charge, to any person obtaining a
00012  * copy of this software and associated documentation files (the "Software"),
00013  * to deal in the Software without restriction, including without limitation
00014  * the rights to use, copy, modify, merge, publish, distribute, sublicense,
00015  * and/or sell copies of the Software, and to permit persons to whom the
00016  * Software is furnished to do so, subject to the following conditions:
00017  *
00018  * The above copyright notice and this permission notice shall be included
00019  * in all copies or substantial portions of the Software.
00020  *
00021  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
00022  * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
00023  * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
00024  * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
00025  * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
00026  * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
00027  * DEALINGS IN THE SOFTWARE.
00028  ******************************************************************************
00029  *
00030  * $Log: ogr_srs_api.h,v $
00031  * Revision 1.50  2005/02/17 16:34:17  fwarmerdam
00032  * OSRCloneCS() should be OSRClone().
00033  *
00034  * Revision 1.49  2005/02/11 14:21:28  fwarmerdam
00035  * added GEOS projection support
00036  *
00037  * Revision 1.48  2005/01/05 21:02:33  fwarmerdam
00038  * added Goode Homolosine
00039  *
00040  * Revision 1.47  2004/11/11 18:28:45  fwarmerdam
00041  * added Bonne projection support
00042  *
00043  * Revision 1.46  2004/09/23 16:20:13  fwarmerdam
00044  * added OSRCleanup
00045  *
00046  * Revision 1.45  2004/05/12 19:25:54  dron
00047  * SRS_DN_WGS72 constant added.
00048  *
00049  * Revision 1.44  2004/05/10 17:05:14  warmerda
00050  * added AutoIdentifyEPSG()
00051  *
00052  * Revision 1.43  2004/05/06 19:26:04  dron
00053  * Added OSRSetProjection() function.
00054  *
00055  * Revision 1.42  2004/03/04 18:04:45  warmerda
00056  * added importFromDict() support
00057  *
00058  * Revision 1.41  2004/02/07 17:31:21  dron
00059  * Added OSRExportToUSGS() method.
00060  *
00061  * Revision 1.40  2004/02/05 17:07:59  dron
00062  * Support for HOM projection, specified by two points on centerline.
00063  *
00064  * Revision 1.39  2004/02/01 14:23:29  dron
00065  * Added OSRImportFromUSGS().
00066  *
00067  * Revision 1.38  2004/01/24 09:35:00  warmerda
00068  * added TransformEx support to capture per point reprojection failure
00069  *
00070  * Revision 1.37  2003/09/09 07:49:52  dron
00071  * Added OSRExportToPCI().
00072  *
00073  * Revision 1.36  2003/08/31 14:51:01  dron
00074  * Added OSRImportFromPCI().
00075  *
00076  * Revision 1.35  2003/08/18 13:26:01  warmerda
00077  * added SetTMVariant() and related definitions
00078  *
00079  * Revision 1.34  2003/06/21 23:24:36  warmerda
00080  * added Set/Get TOWGS84 calls
00081  *
00082  * Revision 1.33  2003/06/19 17:10:26  warmerda
00083  * a couple fixes in last commit
00084  *
00085  * Revision 1.32  2003/06/18 18:24:17  warmerda
00086  * added projection specific set methods to C API
00087  *
00088  * Revision 1.31  2003/06/10 09:31:12  dron
00089  * Added OSRSetAngularUnits() and OSRGetAngularUnits().
00090  *
00091  * Revision 1.30  2003/05/30 15:39:53  warmerda
00092  * Added override units capability for SetStatePlane()
00093  *
00094  * Revision 1.29  2003/03/21 22:15:11  warmerda
00095  * added C XML import/export entry points
00096  *
00097  * Revision 1.28  2003/03/12 14:29:34  warmerda
00098  * Rename OGRAxisOrientation and OGRDatumType values to avoid conflicts with
00099  * the real OGC definitions in applications such as Cadcorps.
00100  *
00101  * Revision 1.27  2003/02/25 04:53:38  warmerda
00102  * added OSRCopyGeogCSFrom
00103  *
00104  * Revision 1.26  2003/02/06 04:53:12  warmerda
00105  * added Fixup() method
00106  *
00107  * Revision 1.25  2003/01/08 18:14:28  warmerda
00108  * added FixupOrdering()
00109  *
00110  * Revision 1.24  2002/12/16 17:07:13  warmerda
00111  * added NormProjParm functions, and OSRGetPrimeMeridian
00112  *
00113  * Revision 1.23  2002/12/14 22:59:14  warmerda
00114  * added Krovak in ESRI compatible way
00115  *
00116  * Revision 1.22  2002/12/09 18:55:07  warmerda
00117  * moved DMS stuff to gdal/port
00118  *
00119  * Revision 1.21  2002/12/09 16:11:53  warmerda
00120  * added DMS translation
00121  *
00122  * Revision 1.20  2002/11/25 16:12:54  warmerda
00123  * added GetAuthorityCode/Name
00124  *
00125  * Revision 1.19  2002/09/26 18:13:25  warmerda
00126  * avoid double def
00127  *
00128  * Revision 1.18  2002/06/11 18:02:03  warmerda
00129  * add PROJ.4 normalization and EPSG support
00130  *
00131  * Revision 1.17  2001/10/11 19:27:12  warmerda
00132  * upgraded validation infrastructure
00133  *
00134  * Revision 1.16  2001/10/10 20:42:43  warmerda
00135  * added ESRI WKT morphing support
00136  *
00137  * Revision 1.15  2001/09/21 16:21:02  warmerda
00138  * added Clear(), and SetFromUserInput() methods
00139  *
00140  * Revision 1.14  2000/11/09 06:21:32  warmerda
00141  * added limited ESRI prj support
00142  *
00143  * Revision 1.13  2000/10/20 04:19:38  warmerda
00144  * added setstateplane
00145  *
00146  * Revision 1.12  2000/10/16 21:26:07  warmerda
00147  * added some level of LOCAL_CS support
00148  *
00149  * Revision 1.11  2000/09/01 20:58:01  warmerda
00150  * added CPL_DLL for entry points
00151  *
00152  * Revision 1.10  2000/08/30 20:06:14  warmerda
00153  * added projection method list functions
00154  *
00155  * Revision 1.9  2000/08/28 20:13:23  warmerda
00156  * added importFromProj4
00157  *
00158  * Revision 1.8  2000/07/11 01:02:06  warmerda
00159  * added ExportToProj4()
00160  *
00161  * Revision 1.7  2000/07/09 20:48:02  warmerda
00162  * added exportToPrettyWkt
00163  *
00164  * Revision 1.6  2000/05/30 22:45:44  warmerda
00165  * added OSRCloneGeogCS()
00166  *
00167  * Revision 1.5  2000/04/26 18:25:56  warmerda
00168  * added missing CPL_DLL attributes
00169  *
00170  * Revision 1.4  2000/03/22 01:09:43  warmerda
00171  * added SetProjCS and SetWellKnownTextCS
00172  *
00173  * Revision 1.3  2000/03/20 23:33:51  warmerda
00174  * updated docs a bit
00175  *
00176  * Revision 1.2  2000/03/20 22:39:31  warmerda
00177  * Added C API.
00178  *
00179  * Revision 1.1  2000/03/16 19:04:14  warmerda
00180  * New
00181  *
00182  */
00183 
00184 #ifndef _OGR_SRS_API_H_INCLUDED
00185 #define _OGR_SRS_API_H_INCLUDED
00186 
00187 #include "ogr_core.h"
00188 
00189 CPL_C_START
00190 
00199 /* -------------------------------------------------------------------- */
00200 /*      Axis orientations (corresponds to CS_AxisOrientationEnum).      */
00201 /* -------------------------------------------------------------------- */
00202 typedef enum {
00203     OAO_Other=0,
00204     OAO_North=1,
00205     OAO_South=2,
00206     OAO_East=3,
00207     OAO_West=4,
00208     OAO_Up=5,
00209     OAO_Down=6
00210 } OGRAxisOrientation;
00211     
00212 /* -------------------------------------------------------------------- */
00213 /*      Datum types (corresponds to CS_DatumType).                      */
00214 /* -------------------------------------------------------------------- */
00215 
00216 typedef enum {
00217     ODT_HD_Min=1000,
00218     ODT_HD_Other=1000,
00219     ODT_HD_Classic=1001,
00220     ODT_HD_Geocentric=1002,
00221     ODT_HD_Max=1999,
00222     ODT_VD_Min=2000,
00223     ODT_VD_Other=2000,
00224     ODT_VD_Orthometric=2001,
00225     ODT_VD_Ellipsoidal=2002,
00226     ODT_VD_AltitudeBarometric=2003,
00227     ODT_VD_Normal=2004,
00228     ODT_VD_GeoidModelDerived=2005,
00229     ODT_VD_Depth=2006,
00230     ODT_VD_Max=2999,
00231     ODT_LD_Min=10000,
00232     ODT_LD_Max=32767
00233 } OGRDatumType; 
00234 
00235 /* ==================================================================== */
00236 /*      Some "standard" strings.                                        */
00237 /* ==================================================================== */
00238 
00239 #define SRS_PT_ALBERS_CONIC_EQUAL_AREA                                  \
00240                                 "Albers_Conic_Equal_Area"
00241 #define SRS_PT_AZIMUTHAL_EQUIDISTANT "Azimuthal_Equidistant"
00242 #define SRS_PT_CASSINI_SOLDNER  "Cassini_Soldner"
00243 #define SRS_PT_CYLINDRICAL_EQUAL_AREA "Cylindrical_Equal_Area"
00244 #define SRS_PT_BONNE            "Bonne"
00245 #define SRS_PT_ECKERT_IV        "Eckert_IV"
00246 #define SRS_PT_ECKERT_VI        "Eckert_VI"
00247 #define SRS_PT_EQUIDISTANT_CONIC "Equidistant_Conic"
00248 #define SRS_PT_EQUIRECTANGULAR  "Equirectangular"
00249 #define SRS_PT_GALL_STEREOGRAPHIC "Gall_Stereographic"
00250 #define SRS_PT_GEOSTATIONARY_SATELLITE "Geostationary_Satellite"
00251 #define SRS_PT_GOODE_HOMOLOSINE "Goode_Homolosine"
00252 #define SRS_PT_GNOMONIC         "Gnomonic"
00253 #define SRS_PT_HOTINE_OBLIQUE_MERCATOR                                  \
00254                                 "Hotine_Oblique_Mercator"
00255 #define SRS_PT_HOTINE_OBLIQUE_MERCATOR_TWO_POINT_NATURAL_ORIGIN         \
00256                             "Hotine_Oblique_Mercator_Two_Point_Natural_Origin"
00257 #define SRS_PT_LABORDE_OBLIQUE_MERCATOR                                 \
00258                                 "Laborde_Oblique_Mercator"
00259 #define SRS_PT_LAMBERT_CONFORMAL_CONIC_1SP                              \
00260                                 "Lambert_Conformal_Conic_1SP"
00261 #define SRS_PT_LAMBERT_CONFORMAL_CONIC_2SP                              \
00262                                 "Lambert_Conformal_Conic_2SP"
00263 #define SRS_PT_LAMBERT_CONFORMAL_CONIC_2SP_BELGIUM                      \
00264                                 "Lambert_Conformal_Conic_2SP_Belgium)"
00265 #define SRS_PT_LAMBERT_AZIMUTHAL_EQUAL_AREA                     \
00266                                 "Lambert_Azimuthal_Equal_Area"
00267 #define SRS_PT_MERCATOR_1SP     "Mercator_1SP"
00268 #define SRS_PT_MERCATOR_2SP     "Mercator_2SP"
00269 #define SRS_PT_MILLER_CYLINDRICAL "Miller_Cylindrical"
00270 #define SRS_PT_MOLLWEIDE        "Mollweide"
00271 #define SRS_PT_NEW_ZEALAND_MAP_GRID                                     \
00272                                 "New_Zealand_Map_Grid"
00273 #define SRS_PT_OBLIQUE_STEREOGRAPHIC                                    \
00274                                 "Oblique_Stereographic"
00275 #define SRS_PT_ORTHOGRAPHIC     "Orthographic"
00276 #define SRS_PT_POLAR_STEREOGRAPHIC                                      \
00277                                 "Polar_Stereographic"
00278 #define SRS_PT_POLYCONIC        "Polyconic"
00279 #define SRS_PT_ROBINSON         "Robinson"
00280 #define SRS_PT_SINUSOIDAL       "Sinusoidal"
00281 #define SRS_PT_STEREOGRAPHIC    "Stereographic"
00282 #define SRS_PT_SWISS_OBLIQUE_CYLINDRICAL                                \
00283                                 "Swiss_Oblique_Cylindrical"
00284 #define SRS_PT_TRANSVERSE_MERCATOR                                      \
00285                                 "Transverse_Mercator"
00286 #define SRS_PT_TRANSVERSE_MERCATOR_SOUTH_ORIENTED                       \
00287                                 "Transverse_Mercator_South_Orientated"
00288 
00289 /* special mapinfo variants on Transverse Mercator */
00290 #define SRS_PT_TRANSVERSE_MERCATOR_MI_22 \
00291                                 "Transverse_Mercator_MapInfo_22"
00292 #define SRS_PT_TRANSVERSE_MERCATOR_MI_23 \
00293                                 "Transverse_Mercator_MapInfo_23"
00294 #define SRS_PT_TRANSVERSE_MERCATOR_MI_24 \
00295                                 "Transverse_Mercator_MapInfo_24"
00296 #define SRS_PT_TRANSVERSE_MERCATOR_MI_25 \
00297                                 "Transverse_Mercator_MapInfo_25"
00298 
00299 #define SRS_PT_TUNISIA_MINING_GRID                                      \
00300                                 "Tunisia_Mining_Grid"
00301 #define SRS_PT_VANDERGRINTEN    "VanDerGrinten"
00302 #define SRS_PT_KROVAK           "Krovak"
00303 
00304                                 
00305 
00306 #define SRS_PP_CENTRAL_MERIDIAN         "central_meridian"
00307 #define SRS_PP_SCALE_FACTOR             "scale_factor"
00308 #define SRS_PP_STANDARD_PARALLEL_1      "standard_parallel_1"
00309 #define SRS_PP_STANDARD_PARALLEL_2      "standard_parallel_2"
00310 #define SRS_PP_PSEUDO_STD_PARALLEL_1    "pseudo_standard_parallel_1"
00311 #define SRS_PP_LONGITUDE_OF_CENTER      "longitude_of_center"
00312 #define SRS_PP_LATITUDE_OF_CENTER       "latitude_of_center"
00313 #define SRS_PP_LONGITUDE_OF_ORIGIN      "longitude_of_origin"
00314 #define SRS_PP_LATITUDE_OF_ORIGIN       "latitude_of_origin"
00315 #define SRS_PP_FALSE_EASTING            "false_easting"
00316 #define SRS_PP_FALSE_NORTHING           "false_northing"
00317 #define SRS_PP_AZIMUTH                  "azimuth"
00318 #define SRS_PP_LONGITUDE_OF_POINT_1     "longitude_of_point_1"
00319 #define SRS_PP_LATITUDE_OF_POINT_1      "latitude_of_point_1"
00320 #define SRS_PP_LONGITUDE_OF_POINT_2     "longitude_of_point_2"
00321 #define SRS_PP_LATITUDE_OF_POINT_2      "latitude_of_point_2"
00322 #define SRS_PP_LONGITUDE_OF_POINT_3     "longitude_of_point_3"
00323 #define SRS_PP_LATITUDE_OF_POINT_3      "latitude_of_point_3"
00324 #define SRS_PP_RECTIFIED_GRID_ANGLE     "rectified_grid_angle"
00325 #define SRS_PP_LANDSAT_NUMBER           "landsat_number"
00326 #define SRS_PP_PATH_NUMBER              "path_number"
00327 #define SRS_PP_PERSPECTIVE_POINT_HEIGHT "perspective_point_height"
00328 #define SRS_PP_SATELLITE_HEIGHT         "satellite_height"
00329 #define SRS_PP_FIPSZONE                 "fipszone"
00330 #define SRS_PP_ZONE                     "zone"
00331 
00332 #define SRS_UL_METER            "Meter"
00333 #define SRS_UL_FOOT             "Foot (International)" /* or just "FOOT"? */
00334 #define SRS_UL_FOOT_CONV                    "0.3048"
00335 #define SRS_UL_US_FOOT          "U.S. Foot" /* or "US survey foot" */
00336 #define SRS_UL_US_FOOT_CONV                 "0.3048006"
00337 #define SRS_UL_NAUTICAL_MILE    "Nautical Mile"
00338 #define SRS_UL_NAUTICAL_MILE_CONV           "1852.0"
00339 #define SRS_UL_LINK             "Link"          /* Based on US Foot */
00340 #define SRS_UL_LINK_CONV                    "0.20116684023368047"
00341 #define SRS_UL_CHAIN            "Chain"         /* based on US Foot */
00342 #define SRS_UL_CHAIN_CONV                   "2.0116684023368047"
00343 #define SRS_UL_ROD              "Rod"           /* based on US Foot */
00344 #define SRS_UL_ROD_CONV                     "5.02921005842012"
00345 
00346 #define SRS_UA_DEGREE           "degree"
00347 #define SRS_UA_DEGREE_CONV                  "0.0174532925199433"
00348 #define SRS_UA_RADIAN           "radian"
00349 
00350 #define SRS_PM_GREENWICH        "Greenwich"
00351 
00352 #define SRS_DN_NAD27            "North_American_Datum_1927"
00353 #define SRS_DN_NAD83            "North_American_Datum_1983"
00354 #define SRS_DN_WGS72            "WGS_1972"
00355 #define SRS_DN_WGS84            "WGS_1984"
00356 
00357 #define SRS_WGS84_SEMIMAJOR     6378137.0                                
00358 #define SRS_WGS84_INVFLATTENING 298.257223563
00359 
00360 /* -------------------------------------------------------------------- */
00361 /*      C Wrappers for C++ objects and methods.                         */
00362 /* -------------------------------------------------------------------- */
00363 #ifndef _DEFINED_OGRSpatialReferenceH
00364 #define _DEFINED_OGRSpatialReferenceH
00365 
00366 typedef void *OGRSpatialReferenceH;                               
00367 typedef void *OGRCoordinateTransformationH;
00368 
00369 #endif
00370 
00371 
00372 OGRSpatialReferenceH CPL_DLL
00373       OSRNewSpatialReference( const char * /* = NULL */);
00374 OGRSpatialReferenceH CPL_DLL OSRCloneGeogCS( OGRSpatialReferenceH );
00375 OGRSpatialReferenceH CPL_DLL OSRClone( OGRSpatialReferenceH );
00376 void CPL_DLL OSRDestroySpatialReference( OGRSpatialReferenceH );
00377 
00378 int CPL_DLL OSRReference( OGRSpatialReferenceH );
00379 int CPL_DLL OSRDereference( OGRSpatialReferenceH );
00380 
00381 OGRErr CPL_DLL OSRValidate( OGRSpatialReferenceH );
00382 OGRErr CPL_DLL OSRFixupOrdering( OGRSpatialReferenceH );
00383 OGRErr CPL_DLL OSRFixup( OGRSpatialReferenceH );
00384 OGRErr CPL_DLL OSRStripCTParms( OGRSpatialReferenceH );
00385 
00386 OGRErr CPL_DLL OSRImportFromEPSG( OGRSpatialReferenceH, int );
00387 OGRErr CPL_DLL OSRImportFromWkt( OGRSpatialReferenceH, char ** );
00388 OGRErr CPL_DLL OSRImportFromProj4( OGRSpatialReferenceH, const char *);
00389 OGRErr CPL_DLL OSRImportFromESRI( OGRSpatialReferenceH, char **);
00390 OGRErr CPL_DLL OSRImportFromPCI( OGRSpatialReferenceH hSRS, const char *,
00391                                  const char *, double * );
00392 OGRErr CPL_DLL OSRImportFromUSGS( OGRSpatialReferenceH,
00393                                   long, long, double *, long);
00394 OGRErr CPL_DLL OSRImportFromXML( OGRSpatialReferenceH, const char * );
00395 OGRErr CPL_DLL OSRImportFromDict( OGRSpatialReferenceH, const char *, 
00396                                   const char * );
00397 OGRErr CPL_DLL OSRExportToWkt( OGRSpatialReferenceH, char ** );
00398 OGRErr CPL_DLL OSRExportToPrettyWkt( OGRSpatialReferenceH, char **, int);
00399 OGRErr CPL_DLL OSRExportToProj4( OGRSpatialReferenceH, char **);
00400 OGRErr CPL_DLL OSRExportToPCI( OGRSpatialReferenceH, char **, char **,
00401                                double ** );
00402 OGRErr CPL_DLL OSRExportToUSGS( OGRSpatialReferenceH, long *, long *,
00403                                 double **, long * );
00404 OGRErr CPL_DLL OSRExportToXML( OGRSpatialReferenceH, char **, const char * );
00405 
00406 OGRErr CPL_DLL OSRMorphToESRI( OGRSpatialReferenceH );
00407 OGRErr CPL_DLL OSRMorphFromESRI( OGRSpatialReferenceH );
00408 
00409 OGRErr CPL_DLL OSRSetAttrValue( OGRSpatialReferenceH hSRS,
00410                                 const char * pszNodePath,
00411                                 const char * pszNewNodeValue );
00412 const char CPL_DLL * OSRGetAttrValue( OGRSpatialReferenceH hSRS,
00413                            const char * pszName, int iChild /* = 0 */ );
00414 
00415 OGRErr CPL_DLL OSRSetAngularUnits( OGRSpatialReferenceH, const char *, double );
00416 double CPL_DLL OSRGetAngularUnits( OGRSpatialReferenceH, char ** );
00417 OGRErr CPL_DLL OSRSetLinearUnits( OGRSpatialReferenceH, const char *, double );
00418 double CPL_DLL OSRGetLinearUnits( OGRSpatialReferenceH, char ** );
00419 
00420 double CPL_DLL OSRGetPrimeMeridian( OGRSpatialReferenceH, char ** );
00421 
00422 int CPL_DLL OSRIsGeographic( OGRSpatialReferenceH );
00423 int CPL_DLL OSRIsLocal( OGRSpatialReferenceH );
00424 int CPL_DLL OSRIsProjected( OGRSpatialReferenceH );
00425 int CPL_DLL OSRIsSameGeogCS( OGRSpatialReferenceH, OGRSpatialReferenceH );
00426 int CPL_DLL OSRIsSame( OGRSpatialReferenceH, OGRSpatialReferenceH );
00427 
00428 OGRErr CPL_DLL OSRSetLocalCS( OGRSpatialReferenceH hSRS, const char *pszName );
00429 OGRErr CPL_DLL OSRSetProjCS( OGRSpatialReferenceH hSRS, const char * pszName );
00430 OGRErr CPL_DLL OSRSetWellKnownGeogCS( OGRSpatialReferenceH hSRS,
00431                                       const char * pszName );
00432 OGRErr CPL_DLL OSRSetFromUserInput( OGRSpatialReferenceH hSRS, 
00433                                     const char * );
00434 OGRErr CPL_DLL OSRCopyGeogCSFrom( OGRSpatialReferenceH hSRS, 
00435                                   OGRSpatialReferenceH hSrcSRS );
00436 OGRErr CPL_DLL OSRSetTOWGS84( OGRSpatialReferenceH hSRS, 
00437                               double, double, double, 
00438                               double, double, double, double );
00439 OGRErr CPL_DLL OSRGetTOWGS84( OGRSpatialReferenceH hSRS, double *, int );
00440                         
00441 
00442 OGRErr CPL_DLL OSRSetGeogCS( OGRSpatialReferenceH hSRS,
00443                       const char * pszGeogName,
00444                       const char * pszDatumName,
00445                       const char * pszEllipsoidName,
00446                       double dfSemiMajor, double dfInvFlattening,
00447                       const char * pszPMName /* = NULL */,
00448                       double dfPMOffset /* = 0.0 */,
00449                       const char * pszUnits /* = NULL */,
00450                       double dfConvertToRadians /* = 0.0 */ );
00451 
00452 double CPL_DLL OSRGetSemiMajor( OGRSpatialReferenceH, OGRErr * /* = NULL */ );
00453 double CPL_DLL OSRGetSemiMinor( OGRSpatialReferenceH, OGRErr * /* = NULL */ );
00454 double CPL_DLL OSRGetInvFlattening( OGRSpatialReferenceH, OGRErr * /*=NULL*/);
00455 
00456 OGRErr CPL_DLL OSRSetAuthority( OGRSpatialReferenceH hSRS,
00457                          const char * pszTargetKey,
00458                          const char * pszAuthority,
00459                          int nCode );
00460 const char CPL_DLL *OSRGetAuthorityCode( OGRSpatialReferenceH hSRS,
00461                                          const char * pszTargetKey );
00462 const char CPL_DLL *OSRGetAuthorityName( OGRSpatialReferenceH hSRS,
00463                                          const char * pszTargetKey );
00464 OGRErr CPL_DLL OSRSetProjection( OGRSpatialReferenceH, const char * );
00465 OGRErr CPL_DLL OSRSetProjParm( OGRSpatialReferenceH, const char *, double );
00466 double CPL_DLL OSRGetProjParm( OGRSpatialReferenceH hSRS,
00467                         const char * pszParmName, 
00468                         double dfDefault /* = 0.0 */,
00469                         OGRErr * /* = NULL */ );
00470 OGRErr CPL_DLL OSRSetNormProjParm( OGRSpatialReferenceH, const char *, double);
00471 double CPL_DLL OSRGetNormProjParm( OGRSpatialReferenceH hSRS,
00472                                    const char * pszParmName, 
00473                                    double dfDefault /* = 0.0 */,
00474                                    OGRErr * /* = NULL */ );
00475 
00476 OGRErr CPL_DLL OSRSetUTM( OGRSpatialReferenceH hSRS, int nZone, int bNorth );
00477 int    CPL_DLL OSRGetUTMZone( OGRSpatialReferenceH hSRS, int *pbNorth );
00478 OGRErr CPL_DLL OSRSetStatePlane( OGRSpatialReferenceH hSRS, 
00479                                  int nZone, int bNAD83 );
00480 OGRErr CPL_DLL OSRSetStatePlaneWithUnits( OGRSpatialReferenceH hSRS, 
00481                                           int nZone, int bNAD83,
00482                                           const char *pszOverrideUnitName,
00483                                           double dfOverrideUnit );
00484 OGRErr CPL_DLL OSRAutoIdentifyEPSG( OGRSpatialReferenceH hSRS );
00485 
00487 OGRErr CPL_DLL OSRSetACEA( OGRSpatialReferenceH hSRS, double dfStdP1, double dfStdP2,
00488                          double dfCenterLat, double dfCenterLong,
00489                          double dfFalseEasting, double dfFalseNorthing );
00490     
00492 OGRErr CPL_DLL  OSRSetAE( OGRSpatialReferenceH hSRS, double dfCenterLat, double dfCenterLong,
00493                        double dfFalseEasting, double dfFalseNorthing );
00494 
00496 OGRErr CPL_DLL OSRSetBonne(OGRSpatialReferenceH hSRS, 
00497                            double dfStandardParallel, double dfCentralMeridian,
00498                            double dfFalseEasting, double dfFalseNorthing );
00499 
00501 OGRErr CPL_DLL OSRSetCEA( OGRSpatialReferenceH hSRS, double dfStdP1, double dfCentralMeridian,
00502                         double dfFalseEasting, double dfFalseNorthing );
00503 
00505 OGRErr CPL_DLL OSRSetCS( OGRSpatialReferenceH hSRS, double dfCenterLat, double dfCenterLong,
00506                        double dfFalseEasting, double dfFalseNorthing );
00507 
00509 OGRErr CPL_DLL OSRSetEC( OGRSpatialReferenceH hSRS, double dfStdP1, double dfStdP2,
00510                        double dfCenterLat, double dfCenterLong,
00511                        double dfFalseEasting, double dfFalseNorthing );
00512 
00514 OGRErr CPL_DLL OSRSetEckertIV( OGRSpatialReferenceH hSRS, double dfCentralMeridian,
00515                              double dfFalseEasting, double dfFalseNorthing );
00516 
00518 OGRErr CPL_DLL OSRSetEckertVI( OGRSpatialReferenceH hSRS, double dfCentralMeridian,
00519                              double dfFalseEasting, double dfFalseNorthing );
00520 
00522 OGRErr CPL_DLL OSRSetEquirectangular(OGRSpatialReferenceH hSRS,
00523                               double dfCenterLat, double dfCenterLong,
00524                               double dfFalseEasting, double dfFalseNorthing );
00525 
00527 OGRErr CPL_DLL OSRSetGS( OGRSpatialReferenceH hSRS, double dfCentralMeridian,
00528                        double dfFalseEasting, double dfFalseNorthing );
00529     
00531 OGRErr CPL_DLL OSRSetGH( OGRSpatialReferenceH hSRS, double dfCentralMeridian,
00532                          double dfFalseEasting, double dfFalseNorthing );
00533     
00535 OGRErr CPL_DLL OSRSetGEOS( OGRSpatialReferenceH hSRS, double dfSatelliteHeight,
00536                          double dfFalseEasting, double dfFalseNorthing );
00537     
00539 OGRErr CPL_DLL OSRSetGnomonic(OGRSpatialReferenceH hSRS,
00540                               double dfCenterLat, double dfCenterLong,
00541                             double dfFalseEasting, double dfFalseNorthing );
00542 
00544 OGRErr CPL_DLL OSRSetHOM( OGRSpatialReferenceH hSRS,
00545                           double dfCenterLat, double dfCenterLong,
00546                           double dfAzimuth, double dfRectToSkew,
00547                           double dfScale,
00548                           double dfFalseEasting, double dfFalseNorthing );
00549 
00551 OGRErr CPL_DLL OSRSetHOM2PNO( OGRSpatialReferenceH hSRS, double dfCenterLat,
00552                               double dfLat1, double dfLong1,
00553                               double dfLat2, double dfLong2,
00554                               double dfScale,
00555                               double dfFalseEasting, double dfFalseNorthing );
00556 
00558 OGRErr CPL_DLL OSRSetKrovak( OGRSpatialReferenceH hSRS, double dfCenterLat, double dfCenterLong,
00559                            double dfAzimuth, double dfPseudoStdParallelLat,
00560                            double dfScale, 
00561                            double dfFalseEasting, double dfFalseNorthing );
00562 
00564 OGRErr CPL_DLL OSRSetLAEA( OGRSpatialReferenceH hSRS, double dfCenterLat, double dfCenterLong,
00565                          double dfFalseEasting, double dfFalseNorthing );
00566 
00568 OGRErr CPL_DLL OSRSetLCC( OGRSpatialReferenceH hSRS, double dfStdP1, double dfStdP2,
00569                         double dfCenterLat, double dfCenterLong,
00570                         double dfFalseEasting, double dfFalseNorthing );
00571 
00573 OGRErr CPL_DLL OSRSetLCC1SP( OGRSpatialReferenceH hSRS, double dfCenterLat, double dfCenterLong,
00574                            double dfScale,
00575                            double dfFalseEasting, double dfFalseNorthing );
00576 
00578 OGRErr CPL_DLL OSRSetLCCB( OGRSpatialReferenceH hSRS, double dfStdP1, double dfStdP2,
00579                          double dfCenterLat, double dfCenterLong,
00580                          double dfFalseEasting, double dfFalseNorthing );
00581     
00583 OGRErr CPL_DLL OSRSetMC( OGRSpatialReferenceH hSRS, double dfCenterLat, double dfCenterLong,
00584                        double dfFalseEasting, double dfFalseNorthing );
00585 
00587 OGRErr CPL_DLL OSRSetMercator( OGRSpatialReferenceH hSRS, double dfCenterLat, double dfCenterLong,
00588                              double dfScale, 
00589                              double dfFalseEasting, double dfFalseNorthing );
00590 
00592 OGRErr CPL_DLL  OSRSetMollweide( OGRSpatialReferenceH hSRS, double dfCentralMeridian,
00593                               double dfFalseEasting, double dfFalseNorthing );
00594 
00596 OGRErr CPL_DLL OSRSetNZMG( OGRSpatialReferenceH hSRS, double dfCenterLat, double dfCenterLong,
00597                          double dfFalseEasting, double dfFalseNorthing );
00598 
00600 OGRErr CPL_DLL OSRSetOS( OGRSpatialReferenceH hSRS, double dfOriginLat, double dfCMeridian,
00601                        double dfScale,
00602                        double dfFalseEasting,double dfFalseNorthing);
00603     
00605 OGRErr CPL_DLL OSRSetOrthographic( OGRSpatialReferenceH hSRS, double dfCenterLat, double dfCenterLong,
00606                                  double dfFalseEasting,double dfFalseNorthing);
00607 
00609 OGRErr CPL_DLL OSRSetPolyconic( OGRSpatialReferenceH hSRS, double dfCenterLat, double dfCenterLong,
00610                               double dfFalseEasting, double dfFalseNorthing );
00611 
00613 OGRErr CPL_DLL OSRSetPS( OGRSpatialReferenceH hSRS, double dfCenterLat, double dfCenterLong,
00614                        double dfScale,
00615                        double dfFalseEasting, double dfFalseNorthing);
00616     
00618 OGRErr CPL_DLL OSRSetRobinson( OGRSpatialReferenceH hSRS, double dfCenterLong, 
00619                              double dfFalseEasting, double dfFalseNorthing );
00620     
00622 OGRErr CPL_DLL OSRSetSinusoidal( OGRSpatialReferenceH hSRS, double dfCenterLong, 
00623                                double dfFalseEasting, double dfFalseNorthing );
00624     
00626 OGRErr CPL_DLL OSRSetStereographic( OGRSpatialReferenceH hSRS, double dfCenterLat, double dfCenterLong,
00627                                   double dfScale,
00628                                  double dfFalseEasting,double dfFalseNorthing);
00629     
00631 OGRErr CPL_DLL OSRSetSOC( OGRSpatialReferenceH hSRS, double dfLatitudeOfOrigin, double dfCentralMeridian,
00632                         double dfFalseEasting, double dfFalseNorthing );
00633     
00635 OGRErr CPL_DLL OSRSetTM( OGRSpatialReferenceH hSRS, double dfCenterLat, double dfCenterLong,
00636                        double dfScale,
00637                        double dfFalseEasting, double dfFalseNorthing );
00638 
00640 OGRErr CPL_DLL OSRSetTMVariant( 
00641     OGRSpatialReferenceH hSRS, const char *pszVariantName,
00642     double dfCenterLat, double dfCenterLong,
00643     double dfScale,
00644     double dfFalseEasting, double dfFalseNorthing );
00645 
00647 OGRErr CPL_DLL OSRSetTMG( OGRSpatialReferenceH hSRS, double dfCenterLat, double dfCenterLong, 
00648                         double dfFalseEasting, double dfFalseNorthing );
00649 
00651 OGRErr CPL_DLL OSRSetTMSO( OGRSpatialReferenceH hSRS,
00652                            double dfCenterLat, double dfCenterLong,
00653                            double dfScale,
00654                            double dfFalseEasting, double dfFalseNorthing );
00655 
00657 OGRErr CPL_DLL OSRSetVDG( OGRSpatialReferenceH hSRS,
00658                           double dfCenterLong,
00659                           double dfFalseEasting, double dfFalseNorthing );
00660 
00661 void CPL_DLL OSRCleanup( void );
00662 
00663 /* -------------------------------------------------------------------- */
00664 /*      OGRCoordinateTransform C API.                                   */
00665 /* -------------------------------------------------------------------- */
00666 OGRCoordinateTransformationH CPL_DLL
00667 OCTNewCoordinateTransformation( OGRSpatialReferenceH hSourceSRS,
00668                                 OGRSpatialReferenceH hTargetSRS );
00669 void CPL_DLL
00670       OCTDestroyCoordinateTransformation( OGRCoordinateTransformationH );
00671 
00672 int CPL_DLL OCTTransform( OGRCoordinateTransformationH hCT,
00673                   int nCount, double *x, double *y, double *z );
00674 int CPL_DLL OCTTransformEx( OGRCoordinateTransformationH hCT,
00675                             int nCount, double *x, double *y, double *z,
00676                             int *pabSuccess );
00677 
00678 /* this is really private to OGR. */
00679 char *OCTProj4Normalize( const char *pszProj4Src );
00680 
00681 /* -------------------------------------------------------------------- */
00682 /*      Projection transform dictionary query.                          */
00683 /* -------------------------------------------------------------------- */
00684 
00685 char CPL_DLL ** OPTGetProjectionMethods();
00686 char CPL_DLL ** OPTGetParameterList( const char * pszProjectionMethod,
00687                              char ** ppszUserName );
00688 int CPL_DLL OPTGetParameterInfo( const char * pszProjectionMethod,
00689                                  const char * pszParameterName,
00690                                  char ** ppszUserName,
00691                                  char ** ppszType,
00692                                  double *pdfDefaultValue );
00693 
00694 CPL_C_END
00695 
00696 #endif /* ndef _OGR_SRS_API_H_INCLUDED */

Generated on Mon Jan 9 18:03:31 2006 for OGR by  doxygen 1.4.6