gdal.h

Go to the documentation of this file.
00001 /******************************************************************************
00002  * $Id: gdal.h,v 1.90 2005/02/23 14:53:43 fwarmerdam Exp $
00003  *
00004  * Name:     gdal.h
00005  * Project:  GDAL Core
00006  * Purpose:  GDAL Core C/Public declarations.
00007  * Author:   Frank Warmerdam, warmerdam@pobox.com
00008  *
00009  ******************************************************************************
00010  * Copyright (c) 1998, 2002 Frank Warmerdam
00011  *
00012  * Permission is hereby granted, free of charge, to any person obtaining a
00013  * copy of this software and associated documentation files (the "Software"),
00014  * to deal in the Software without restriction, including without limitation
00015  * the rights to use, copy, modify, merge, publish, distribute, sublicense,
00016  * and/or sell copies of the Software, and to permit persons to whom the
00017  * Software is furnished to do so, subject to the following conditions:
00018  *
00019  * The above copyright notice and this permission notice shall be included
00020  * in all copies or substantial portions of the Software.
00021  *
00022  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
00023  * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
00024  * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
00025  * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
00026  * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
00027  * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
00028  * DEALINGS IN THE SOFTWARE.
00029  ******************************************************************************
00030  *
00031  * $Log: gdal.h,v $
00032  * Revision 1.90  2005/02/23 14:53:43  fwarmerdam
00033  * moved version info into gdal_version.h
00034  *
00035  * Revision 1.89  2005/02/10 04:30:29  fwarmerdam
00036  * added support for YCbCr color space
00037  *
00038  * Revision 1.88  2004/12/02 18:26:07  fwarmerdam
00039  * added CPL_DLL specifier on two functions.
00040  *
00041  * Revision 1.87  2004/11/22 20:06:50  fwarmerdam
00042  * Updated to 1.2.5.
00043  *
00044  * Revision 1.86  2004/11/05 18:00:04  fwarmerdam
00045  * Updated to 1.2.4.0.
00046  *
00047  * Revision 1.85  2004/10/18 17:22:07  fwarmerdam
00048  * added GCI_Max
00049  *
00050  * Revision 1.84  2004/09/25 05:51:03  fwarmerdam
00051  * updated to version 1.2.3
00052  *
00053  * Revision 1.83  2004/09/16 18:30:13  fwarmerdam
00054  * Updated to 1.2.2.
00055  *
00056  * Revision 1.82  2004/06/24 03:10:49  warmerda
00057  * update to GDAL 1.2.1
00058  *
00059  * Revision 1.81  2004/04/29 13:42:58  warmerda
00060  * added C Offset/Scale entry points
00061  *
00062  * Revision 1.80  2004/04/04 20:05:37  warmerda
00063  * mark as 1.2.0.1
00064  *
00065  * Revision 1.79  2004/04/02 17:32:40  warmerda
00066  * added GDALGeneralCmdLineProcessor()
00067  *
00068  * Revision 1.78  2004/03/28 16:01:46  warmerda
00069  * added GDALApplyGeoTransform()
00070  *
00071  * Revision 1.77  2004/03/10 19:18:29  warmerda
00072  * updated date
00073  *
00074  * Revision 1.76  2004/03/01 18:30:44  warmerda
00075  * Updated release date.
00076  *
00077  * Revision 1.75  2004/02/25 09:03:15  dron
00078  * Added GDALPackedDMSToDec() and GDALDecToPackedDMS() functions.
00079  *
00080  * Revision 1.74  2004/02/19 15:55:52  warmerda
00081  * updated to 1.2.0
00082  *
00083  * Revision 1.73  2004/02/04 21:30:12  warmerda
00084  * ensure GDALGetDataTypeByName is exported
00085  *
00086  * Revision 1.72  2004/01/18 16:43:37  dron
00087  * Added GDALGetDataTypeByName() function.
00088  *
00089  * Revision 1.71  2003/07/18 04:46:48  sperkins
00090  * added CPL_DLL to GDALFillRaster
00091  *
00092  * Revision 1.70  2003/06/27 20:03:11  warmerda
00093  * updated version to 1.1.9
00094  *
00095  * Revision 1.69  2003/06/03 19:44:00  warmerda
00096  * added GDALRPCInfo support
00097  *
00098  * Revision 1.68  2003/05/06 05:20:38  sperkins
00099  * cleaned up comments
00100  *
00101  * Revision 1.67  2003/05/06 05:13:36  sperkins
00102  * added Fill() and GDALFillRaster()
00103  *
00104  * Revision 1.66  2003/05/02 19:47:57  warmerda
00105  * added C GetBandNumber and GetBandDataset entry points
00106  *
00107  * Revision 1.65  2003/04/30 17:13:48  warmerda
00108  * added docs for many C functions
00109  *
00110  * Revision 1.64  2003/04/30 15:48:31  warmerda
00111  * Fixed email address, trimmed log messages.
00112  *
00113  * Revision 1.63  2003/04/25 19:46:13  warmerda
00114  * added GDALDatasetRasterIO
00115  *
00116  * Revision 1.62  2003/03/18 06:01:03  warmerda
00117  * Added GDALFlushCache()
00118  *
00119  * Revision 1.61  2003/02/20 18:34:12  warmerda
00120  * added GDALGetRasterAccess()
00121  *
00122  * Revision 1.60  2003/01/27 21:55:52  warmerda
00123  * various documentation improvements
00124  *
00125  * Revision 1.59  2002/12/21 17:28:35  warmerda
00126  * actually, lets use 1.1.8.0
00127  *
00128  * Revision 1.58  2002/12/21 17:26:43  warmerda
00129  * updated version to 1.1.7.5
00130  *
00131  * Revision 1.57  2002/12/05 15:46:38  warmerda
00132  * added GDALReadTabFile()
00133  *
00134  * Revision 1.56  2002/11/23 18:07:41  warmerda
00135  * added DMD_CREATIONDATATYPES
00136  *
00137  * Revision 1.55  2002/10/24 14:18:29  warmerda
00138  * intermediate version update
00139  *
00140  * Revision 1.54  2002/09/11 14:17:38  warmerda
00141  * added C GDALSetDescription()
00142  *
00143  * Revision 1.53  2002/09/06 01:29:55  warmerda
00144  * added C entry points for GetAccess() and GetOpenDatasets()
00145  *
00146  * Revision 1.52  2002/09/04 06:52:35  warmerda
00147  * added GDALDestroyDriverManager
00148  *
00149  * Revision 1.51  2002/07/09 20:33:12  warmerda
00150  * expand tabs
00151  *
00152  * Revision 1.50  2002/06/12 21:13:27  warmerda
00153  * use metadata based driver info
00154  *
00155  * Revision 1.49  2002/05/28 18:55:46  warmerda
00156  * added GDALOpenShared() and GDALDumpOpenDatasets
00157  *
00158  * Revision 1.48  2002/05/14 21:38:32  warmerda
00159  * make INST_DATA overidable with binary patch
00160  *
00161  * Revision 1.47  2002/05/06 21:37:29  warmerda
00162  * added GDALGCPsToGeoTransform
00163  *
00164  * Revision 1.46  2002/04/24 16:25:04  warmerda
00165  * Ensure that GDAL{Read,Write}WorldFile() are exported on Windows.
00166  *
00167  * Revision 1.45  2002/04/19 12:22:05  dron
00168  * added GDALWriteWorldFile()
00169  *
00170  * Revision 1.44  2002/04/16 13:59:33  warmerda
00171  * added GDALVersionInfo
00172  *
00173  * Revision 1.43  2002/04/16 13:26:08  warmerda
00174  * upgrade to version 1.1.7
00175  */
00176 
00177 #ifndef GDAL_H_INCLUDED
00178 #define GDAL_H_INCLUDED
00179 
00186 #include "gdal_version.h"
00187 #include "cpl_port.h"
00188 #include "cpl_error.h"
00189 
00190 /* -------------------------------------------------------------------- */
00191 /*      Significant constants.                                          */
00192 /* -------------------------------------------------------------------- */
00193 
00194 CPL_C_START
00195 
00197 typedef enum {
00198     GDT_Unknown = 0,           GDT_Byte = 1,         GDT_UInt16 = 2,           GDT_Int16 = 3,      GDT_UInt32 = 4,        GDT_Int32 = 5,        GDT_Float32 = 6,        GDT_Float64 = 7,                        GDT_CInt16 = 8,                        GDT_CInt32 = 9,                      GDT_CFloat32 = 10,                      GDT_CFloat64 = 11,
00210     GDT_TypeCount = 12          /* maximum type # + 1 */
00211 } GDALDataType;
00212 
00213 int CPL_DLL GDALGetDataTypeSize( GDALDataType );
00214 int CPL_DLL GDALDataTypeIsComplex( GDALDataType );
00215 const char CPL_DLL *GDALGetDataTypeName( GDALDataType );
00216 GDALDataType CPL_DLL GDALGetDataTypeByName( const char * );
00217 GDALDataType CPL_DLL GDALDataTypeUnion( GDALDataType, GDALDataType );
00218 
00220 typedef enum { GA_ReadOnly = 0,           GA_Update = 1
00223 } GDALAccess;
00224 
00226 typedef enum {   GF_Read = 0,  GF_Write = 1
00229 } GDALRWFlag;
00230 
00232 typedef enum
00233 {
00234     GCI_Undefined=0,                                      GCI_GrayIndex=1,          GCI_PaletteIndex=2,                         GCI_RedBand=3,                       GCI_GreenBand=4,                        GCI_BlueBand=5,              GCI_AlphaBand=6,                          GCI_HueBand=7,                   GCI_SaturationBand=8,                    GCI_LightnessBand=9,                        GCI_CyanBand=10,                     GCI_MagentaBand=11,                      GCI_YellowBand=12,                       GCI_BlackBand=13,                                    GCI_YCbCr_YBand=14,                                      GCI_YCbCr_CbBand=15,                                      GCI_YCbCr_CrBand=16,                              GCI_Max=16
00252 } GDALColorInterp;
00253 
00255 const char CPL_DLL *GDALGetColorInterpretationName( GDALColorInterp );
00256 
00258 typedef enum 
00259 {                      GPI_Gray=0,  GPI_RGB=1, GPI_CMYK=2,     GPI_HLS=3
00264 } GDALPaletteInterp;
00265 
00267 const char CPL_DLL *GDALGetPaletteInterpretationName( GDALPaletteInterp );
00268 
00269 /* -------------------------------------------------------------------- */
00270 /*      GDAL Specific error codes.                                      */
00271 /*                                                                      */
00272 /*      error codes 100 to 299 reserved for GDAL.                       */
00273 /* -------------------------------------------------------------------- */
00274 #define CPLE_WrongFormat        200
00275 
00276 /* -------------------------------------------------------------------- */
00277 /*      Define handle types related to various internal classes.        */
00278 /* -------------------------------------------------------------------- */
00279 typedef void *GDALMajorObjectH;
00280 typedef void *GDALDatasetH;
00281 typedef void *GDALRasterBandH;
00282 typedef void *GDALDriverH;
00283 typedef void *GDALProjDefH;
00284 typedef void *GDALColorTableH;
00285 
00286 /* -------------------------------------------------------------------- */
00287 /*      Callback "progress" function.                                   */
00288 /* -------------------------------------------------------------------- */
00289 
00290 typedef int (*GDALProgressFunc)(double,const char *, void *);
00291 int CPL_DLL GDALDummyProgress( double, const char *, void *);
00292 int CPL_DLL GDALTermProgress( double, const char *, void *);
00293 int CPL_DLL GDALScaledProgress( double, const char *, void *);
00294 void CPL_DLL *GDALCreateScaledProgress( double, double,
00295                                         GDALProgressFunc, void * );
00296 void CPL_DLL GDALDestroyScaledProgress( void * );
00297 
00298 /* ==================================================================== */
00299 /*      Registration/driver related.                                    */
00300 /* ==================================================================== */
00301 
00302 typedef struct {
00303     char      *pszOptionName;
00304     char      *pszValueType;   /* "boolean", "int", "float", "string", 
00305                                   "string-select" */
00306     char      *pszDescription;
00307     char      **papszOptions;
00308 } GDALOptionDefinition;
00309 
00310 #define GDAL_DMD_LONGNAME "DMD_LONGNAME"
00311 #define GDAL_DMD_HELPTOPIC "DMD_HELPTOPIC"
00312 #define GDAL_DMD_MIMETYPE "DMD_MIMETYPE"
00313 #define GDAL_DMD_EXTENSION "DMD_EXTENSION"
00314 #define GDAL_DMD_CREATIONOPTIONLIST "DMD_CREATIONOPTIONLIST" 
00315 #define GDAL_DMD_CREATIONDATATYPES "DMD_CREATIONDATATYPES" 
00316 
00317 #define GDAL_DCAP_CREATE     "DCAP_CREATE"
00318 #define GDAL_DCAP_CREATECOPY "DCAP_CREATECOPY"
00319 
00320 void CPL_DLL GDALAllRegister( void );
00321 
00322 GDALDatasetH CPL_DLL GDALCreate( GDALDriverH hDriver,
00323                                  const char *, int, int, int, GDALDataType,
00324                                  char ** );
00325 GDALDatasetH CPL_DLL GDALCreateCopy( GDALDriverH, const char *, GDALDatasetH,
00326                                      int, char **, GDALProgressFunc, void * );
00327 
00328 GDALDatasetH CPL_DLL GDALOpen( const char *pszFilename, GDALAccess eAccess );
00329 GDALDatasetH CPL_DLL GDALOpenShared( const char *, GDALAccess );
00330 int          CPL_DLL GDALDumpOpenDatasets( FILE * );
00331 
00332 GDALDriverH CPL_DLL GDALGetDriverByName( const char * );
00333 int CPL_DLL         GDALGetDriverCount();
00334 GDALDriverH CPL_DLL GDALGetDriver( int );
00335 int         CPL_DLL GDALRegisterDriver( GDALDriverH );
00336 void        CPL_DLL GDALDeregisterDriver( GDALDriverH );
00337 void        CPL_DLL GDALDestroyDriverManager( void );
00338 CPLErr      CPL_DLL GDALDeleteDataset( GDALDriverH, const char * );
00339 
00340 /* The following are deprecated */
00341 const char CPL_DLL *GDALGetDriverShortName( GDALDriverH );
00342 const char CPL_DLL *GDALGetDriverLongName( GDALDriverH );
00343 const char CPL_DLL *GDALGetDriverHelpTopic( GDALDriverH );
00344 
00345 /* ==================================================================== */
00346 /*      GDAL_GCP                                                        */
00347 /* ==================================================================== */
00348 
00350 typedef struct
00351 {
00353     char        *pszId; 
00354 
00356     char        *pszInfo;
00357 
00359     double      dfGCPPixel;
00361     double      dfGCPLine;
00362 
00364     double      dfGCPX;
00365 
00367     double      dfGCPY;
00368 
00370     double      dfGCPZ;
00371 } GDAL_GCP;
00372 
00373 void CPL_DLL GDALInitGCPs( int, GDAL_GCP * );
00374 void CPL_DLL GDALDeinitGCPs( int, GDAL_GCP * );
00375 GDAL_GCP CPL_DLL *GDALDuplicateGCPs( int, const GDAL_GCP * );
00376 
00377 int CPL_DLL GDALGCPsToGeoTransform( int nGCPCount, const GDAL_GCP *pasGCPs, 
00378                                     double *padfGeoTransform, int bApproxOK ); 
00379 int CPL_DLL GDALInvGeoTransform( double *padfGeoTransformIn, 
00380                                  double *padfInvGeoTransformOut );
00381 void CPL_DLL GDALApplyGeoTransform( double *, double, double, 
00382                                     double *, double * );
00383 
00384 /* ==================================================================== */
00385 /*      major objects (dataset, and, driver, drivermanager).            */
00386 /* ==================================================================== */
00387 
00388 char CPL_DLL  **GDALGetMetadata( GDALMajorObjectH, const char * );
00389 CPLErr CPL_DLL  GDALSetMetadata( GDALMajorObjectH, char **,
00390                                  const char * );
00391 const char CPL_DLL *GDALGetMetadataItem( GDALMajorObjectH, const char *, 
00392                                          const char * );
00393 CPLErr CPL_DLL  GDALSetMetadataItem( GDALMajorObjectH,
00394                                      const char *, const char *,
00395                                      const char * );
00396 const char CPL_DLL *GDALGetDescription( GDALMajorObjectH );
00397 void       CPL_DLL  GDALSetDescription( GDALMajorObjectH, const char * );
00398 
00399 /* ==================================================================== */
00400 /*      GDALDataset class ... normally this represents one file.        */
00401 /* ==================================================================== */
00402 
00403 GDALDriverH CPL_DLL GDALGetDatasetDriver( GDALDatasetH );
00404 void CPL_DLL   GDALClose( GDALDatasetH );
00405 int CPL_DLL     GDALGetRasterXSize( GDALDatasetH );
00406 int CPL_DLL     GDALGetRasterYSize( GDALDatasetH );
00407 int CPL_DLL     GDALGetRasterCount( GDALDatasetH );
00408 GDALRasterBandH CPL_DLL GDALGetRasterBand( GDALDatasetH, int );
00409 
00410 CPLErr CPL_DLL  GDALAddBand( GDALDatasetH hDS, GDALDataType eType, 
00411                              char **papszOptions );
00412 
00413 CPLErr CPL_DLL GDALDatasetRasterIO( 
00414     GDALDatasetH hDS, GDALRWFlag eRWFlag,
00415     int nDSXOff, int nDSYOff, int nDSXSize, int nDSYSize,
00416     void * pBuffer, int nBXSize, int nBYSize, GDALDataType eBDataType,
00417     int nBandCount, int *panBandCount, 
00418     int nPixelSpace, int nLineSpace, int nBandSpace);
00419 
00420 CPLErr CPL_DLL GDALDatasetAdviseRead( GDALDatasetH hDS, 
00421     int nDSXOff, int nDSYOff, int nDSXSize, int nDSYSize,
00422     int nBXSize, int nBYSize, GDALDataType eBDataType,
00423     int nBandCount, int *panBandCount, char **papszOptions );
00424 
00425 const char CPL_DLL *GDALGetProjectionRef( GDALDatasetH );
00426 CPLErr CPL_DLL  GDALSetProjection( GDALDatasetH, const char * );
00427 CPLErr CPL_DLL  GDALGetGeoTransform( GDALDatasetH, double * );
00428 CPLErr CPL_DLL  GDALSetGeoTransform( GDALDatasetH, double * );
00429 
00430 int CPL_DLL     GDALGetGCPCount( GDALDatasetH );
00431 const char CPL_DLL *GDALGetGCPProjection( GDALDatasetH );
00432 const GDAL_GCP CPL_DLL *GDALGetGCPs( GDALDatasetH );
00433 CPLErr CPL_DLL  GDALSetGCPs( GDALDatasetH, int, const GDAL_GCP *,
00434                              const char * );
00435 
00436 void CPL_DLL   *GDALGetInternalHandle( GDALDatasetH, const char * );
00437 int CPL_DLL     GDALReferenceDataset( GDALDatasetH );
00438 int CPL_DLL     GDALDereferenceDataset( GDALDatasetH );
00439 
00440 CPLErr CPL_DLL  GDALBuildOverviews( GDALDatasetH, const char *, int, int *,
00441                                     int, int *, GDALProgressFunc, void * );
00442 void CPL_DLL    GDALGetOpenDatasets( GDALDatasetH ***hDS, int *pnCount );
00443 int CPL_DLL     GDALGetAccess( GDALDatasetH hDS );
00444 void CPL_DLL    GDALFlushCache( GDALDatasetH hDS );
00445 
00446 /* ==================================================================== */
00447 /*      GDALRasterBand ... one band/channel in a dataset.               */
00448 /* ==================================================================== */
00449 
00450 GDALDataType CPL_DLL GDALGetRasterDataType( GDALRasterBandH );
00451 void CPL_DLL    GDALGetBlockSize( GDALRasterBandH,
00452                                   int * pnXSize, int * pnYSize );
00453 
00454 CPLErr CPL_DLL GDALRasterAdviseRead( GDALRasterBandH hRB, 
00455     int nDSXOff, int nDSYOff, int nDSXSize, int nDSYSize,
00456     int nBXSize, int nBYSize, GDALDataType eBDataType, char **papszOptions );
00457 
00458 CPLErr CPL_DLL GDALRasterIO( GDALRasterBandH hRBand, GDALRWFlag eRWFlag,
00459                               int nDSXOff, int nDSYOff,
00460                               int nDSXSize, int nDSYSize,
00461                               void * pBuffer, int nBXSize, int nBYSize,
00462                               GDALDataType eBDataType,
00463                               int nPixelSpace, int nLineSpace );
00464 CPLErr CPL_DLL GDALReadBlock( GDALRasterBandH, int, int, void * );
00465 CPLErr CPL_DLL GDALWriteBlock( GDALRasterBandH, int, int, void * );
00466 int CPL_DLL GDALGetRasterBandXSize( GDALRasterBandH );
00467 int CPL_DLL GDALGetRasterBandYSize( GDALRasterBandH );
00468 char CPL_DLL  **GDALGetRasterMetadata( GDALRasterBandH );
00469 GDALAccess CPL_DLL GDALGetRasterAccess( GDALRasterBandH );
00470 int CPL_DLL GDALGetBandNumber( GDALRasterBandH );
00471 GDALDatasetH CPL_DLL GDALGetBandDataset( GDALRasterBandH );
00472 
00473 GDALColorInterp CPL_DLL GDALGetRasterColorInterpretation( GDALRasterBandH );
00474 CPLErr CPL_DLL GDALSetRasterColorInterpretation( GDALRasterBandH,
00475                                                  GDALColorInterp );
00476 GDALColorTableH CPL_DLL GDALGetRasterColorTable( GDALRasterBandH );
00477 CPLErr CPL_DLL GDALSetRasterColorTable( GDALRasterBandH, GDALColorTableH );
00478 int CPL_DLL     GDALHasArbitraryOverviews( GDALRasterBandH );
00479 int CPL_DLL             GDALGetOverviewCount( GDALRasterBandH );
00480 GDALRasterBandH CPL_DLL GDALGetOverview( GDALRasterBandH, int );
00481 double CPL_DLL GDALGetRasterNoDataValue( GDALRasterBandH, int * );
00482 CPLErr CPL_DLL GDALSetRasterNoDataValue( GDALRasterBandH, double );
00483 char CPL_DLL ** GDALGetRasterCategoryNames( GDALRasterBandH );
00484 CPLErr CPL_DLL GDALSetRasterCategoryNames( GDALRasterBandH, char ** );
00485 double CPL_DLL GDALGetRasterMinimum( GDALRasterBandH, int *pbSuccess );
00486 double CPL_DLL GDALGetRasterMaximum( GDALRasterBandH, int *pbSuccess );
00487 const char CPL_DLL *GDALGetRasterUnitType( GDALRasterBandH );
00488 double CPL_DLL GDALGetRasterOffset( GDALRasterBandH, int *pbSuccess );
00489 double CPL_DLL GDALGetRasterScale( GDALRasterBandH, int *pbSuccess );
00490 void CPL_DLL GDALComputeRasterMinMax( GDALRasterBandH hBand, int bApproxOK,
00491                                       double adfMinMax[2] );
00492 CPLErr CPL_DLL GDALFlushRasterCache( GDALRasterBandH hBand );
00493 CPLErr CPL_DLL GDALGetRasterHistogram( GDALRasterBandH hBand,
00494                                        double dfMin, double dfMax,
00495                                        int nBuckets, int *panHistogram,
00496                                        int bIncludeOutOfRange, int bApproxOK,
00497                                        GDALProgressFunc pfnProgress,
00498                                        void * pProgressData );
00499 int CPL_DLL GDALGetRandomRasterSample( GDALRasterBandH, int, float * );
00500 GDALRasterBandH CPL_DLL GDALGetRasterSampleOverview( GDALRasterBandH, int );
00501 CPLErr CPL_DLL GDALFillRaster( GDALRasterBandH hBand, double dfRealValue,
00502                        double dfImaginaryValue );
00503 CPLErr CPL_DLL GDALComputeBandStats( GDALRasterBandH hBand, int nSampleStep, 
00504                              double *pdfMean, double *pdfStdDev, 
00505                              GDALProgressFunc pfnProgress,
00506                              void *pProgressData );
00507 CPLErr CPL_DLL  GDALOverviewMagnitudeCorrection( GDALRasterBandH hBaseBand, 
00508                                         int nOverviewCount, 
00509                                         GDALRasterBandH *pahOverviews, 
00510                                         GDALProgressFunc pfnProgress, 
00511                                         void *pProgressData );
00512 
00513 /* -------------------------------------------------------------------- */
00514 /*      Helper functions.                                               */
00515 /* -------------------------------------------------------------------- */
00516 int CPL_DLL GDALGeneralCmdLineProcessor( int nArgc, char ***ppapszArgv, 
00517                                          int nOptions );
00518 void CPL_DLL GDALSwapWords( void *pData, int nWordSize, int nWordCount,
00519                             int nWordSkip );
00520 void CPL_DLL
00521     GDALCopyWords( void * pSrcData, GDALDataType eSrcType, int nSrcPixelOffset,
00522                    void * pDstData, GDALDataType eDstType, int nDstPixelOffset,
00523                    int nWordCount );
00524 
00525 int CPL_DLL GDALReadWorldFile( const char *pszBaseFilename, 
00526                        const char *pszExtension, 
00527                        double * padfGeoTransform );
00528 int CPL_DLL GDALWriteWorldFile( const char *pszBaseFilename, 
00529                        const char *pszExtension, 
00530                        double * padfGeoTransform );
00531 int CPL_DLL GDALReadTabFile( const char *pszBaseFilename, 
00532                              double *padfGeoTransform, char **ppszWKT,
00533                              int *pnGCPCount, GDAL_GCP **ppasGCPs );
00534 
00535 const char CPL_DLL *GDALDecToDMS( double, const char *, int );
00536 double CPL_DLL GDALPackedDMSToDec( double );
00537 double CPL_DLL GDALDecToPackedDMS( double );
00538 
00539 const char CPL_DLL *GDALVersionInfo( const char * );
00540 
00541 typedef struct { 
00542     double      dfLINE_OFF;
00543     double      dfSAMP_OFF;
00544     double      dfLAT_OFF;
00545     double      dfLONG_OFF;
00546     double      dfHEIGHT_OFF;
00547 
00548     double      dfLINE_SCALE;
00549     double      dfSAMP_SCALE;
00550     double      dfLAT_SCALE;
00551     double      dfLONG_SCALE;
00552     double      dfHEIGHT_SCALE;
00553 
00554     double      adfLINE_NUM_COEFF[20];
00555     double      adfLINE_DEN_COEFF[20];
00556     double      adfSAMP_NUM_COEFF[20];
00557     double      adfSAMP_DEN_COEFF[20];
00558     
00559     double      dfMIN_LONG;
00560     double      dfMIN_LAT;
00561     double      dfMAX_LONG;
00562     double      dfMAX_LAT;
00563 
00564 } GDALRPCInfo;
00565 
00566 int CPL_DLL GDALExtractRPCInfo( char **, GDALRPCInfo * );
00567 
00568 /* ==================================================================== */
00569 /*      Color tables.                                                   */
00570 /* ==================================================================== */
00572 typedef struct
00573 {
00575     short      c1;      
00576 
00578     short      c2;      
00579 
00581     short      c3;      
00582 
00584     short      c4;      
00585 } GDALColorEntry;
00586 
00587 GDALColorTableH CPL_DLL GDALCreateColorTable( GDALPaletteInterp );
00588 void CPL_DLL            GDALDestroyColorTable( GDALColorTableH );
00589 GDALColorTableH CPL_DLL GDALCloneColorTable( GDALColorTableH );
00590 GDALPaletteInterp CPL_DLL GDALGetPaletteInterpretation( GDALColorTableH );
00591 int CPL_DLL             GDALGetColorEntryCount( GDALColorTableH );
00592 const GDALColorEntry CPL_DLL *GDALGetColorEntry( GDALColorTableH, int );
00593 int CPL_DLL GDALGetColorEntryAsRGB( GDALColorTableH, int, GDALColorEntry *);
00594 void CPL_DLL GDALSetColorEntry( GDALColorTableH, int, const GDALColorEntry * );
00595 
00596 /* ==================================================================== */
00597 /*      GDAL Cache Management                                           */
00598 /* ==================================================================== */
00599 
00600 void CPL_DLL GDALSetCacheMax( int nBytes );
00601 int CPL_DLL GDALGetCacheMax();
00602 int CPL_DLL GDALGetCacheUsed();
00603 int CPL_DLL GDALFlushCacheBlock();
00604 
00605 CPL_C_END
00606 
00607 #endif /* ndef GDAL_H_INCLUDED */

Generated on Mon Jan 9 18:03:35 2006 for GDAL by  doxygen 1.4.6