Main Page | Class Hierarchy | Class List | File List | Class Members | File Members | Related Pages

gdal.h

Go to the documentation of this file.
00001 /******************************************************************************
00002  * $Id: gdal.h,v 1.97 2005/05/24 18:13:15 dron 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.97  2005/05/24 18:13:15  dron
00033  * Added GDALGetDriverCreationOptionList() function.
00034  *
00035  * Revision 1.96  2005/05/16 21:34:33  fwarmerdam
00036  * Added SetDefaultHistogram
00037  *
00038  * Revision 1.95  2005/05/11 14:04:08  fwarmerdam
00039  * added getdefaulthistogram
00040  *
00041  * Revision 1.94  2005/04/27 16:28:39  fwarmerdam
00042  * added GDALGetRasterStatistics
00043  *
00044  * Revision 1.93  2005/04/15 18:34:52  fwarmerdam
00045  * Added area or point metadata constants.
00046  *
00047  * Revision 1.92  2005/04/04 15:24:48  fwarmerdam
00048  * Most C entry points now CPL_STDCALL
00049  *
00050  * Revision 1.91  2005/03/16 19:21:35  fwarmerdam
00051  * added methods for setting offset/scale
00052  *
00053  * Revision 1.90  2005/02/23 14:53:43  fwarmerdam
00054  * moved version info into gdal_version.h
00055  *
00056  * Revision 1.89  2005/02/10 04:30:29  fwarmerdam
00057  * added support for YCbCr color space
00058  *
00059  * Revision 1.88  2004/12/02 18:26:07  fwarmerdam
00060  * added CPL_DLL specifier on two functions.
00061  *
00062  * Revision 1.87  2004/11/22 20:06:50  fwarmerdam
00063  * Updated to 1.2.5.
00064  *
00065  * Revision 1.86  2004/11/05 18:00:04  fwarmerdam
00066  * Updated to 1.2.4.0.
00067  *
00068  * Revision 1.85  2004/10/18 17:22:07  fwarmerdam
00069  * added GCI_Max
00070  *
00071  * Revision 1.84  2004/09/25 05:51:03  fwarmerdam
00072  * updated to version 1.2.3
00073  *
00074  * Revision 1.83  2004/09/16 18:30:13  fwarmerdam
00075  * Updated to 1.2.2.
00076  *
00077  * Revision 1.82  2004/06/24 03:10:49  warmerda
00078  * update to GDAL 1.2.1
00079  *
00080  * Revision 1.81  2004/04/29 13:42:58  warmerda
00081  * added C Offset/Scale entry points
00082  *
00083  * Revision 1.80  2004/04/04 20:05:37  warmerda
00084  * mark as 1.2.0.1
00085  *
00086  * Revision 1.79  2004/04/02 17:32:40  warmerda
00087  * added GDALGeneralCmdLineProcessor()
00088  *
00089  * Revision 1.78  2004/03/28 16:01:46  warmerda
00090  * added GDALApplyGeoTransform()
00091  *
00092  * Revision 1.77  2004/03/10 19:18:29  warmerda
00093  * updated date
00094  *
00095  * Revision 1.76  2004/03/01 18:30:44  warmerda
00096  * Updated release date.
00097  *
00098  * Revision 1.75  2004/02/25 09:03:15  dron
00099  * Added GDALPackedDMSToDec() and GDALDecToPackedDMS() functions.
00100  *
00101  * Revision 1.74  2004/02/19 15:55:52  warmerda
00102  * updated to 1.2.0
00103  *
00104  * Revision 1.73  2004/02/04 21:30:12  warmerda
00105  * ensure GDALGetDataTypeByName is exported
00106  *
00107  * Revision 1.72  2004/01/18 16:43:37  dron
00108  * Added GDALGetDataTypeByName() function.
00109  *
00110  * Revision 1.71  2003/07/18 04:46:48  sperkins
00111  * added CPL_DLL to GDALFillRaster
00112  *
00113  * Revision 1.70  2003/06/27 20:03:11  warmerda
00114  * updated version to 1.1.9
00115  *
00116  * Revision 1.69  2003/06/03 19:44:00  warmerda
00117  * added GDALRPCInfo support
00118  *
00119  * Revision 1.68  2003/05/06 05:20:38  sperkins
00120  * cleaned up comments
00121  *
00122  * Revision 1.67  2003/05/06 05:13:36  sperkins
00123  * added Fill() and GDALFillRaster()
00124  *
00125  * Revision 1.66  2003/05/02 19:47:57  warmerda
00126  * added C GetBandNumber and GetBandDataset entry points
00127  *
00128  * Revision 1.65  2003/04/30 17:13:48  warmerda
00129  * added docs for many C functions
00130  *
00131  * Revision 1.64  2003/04/30 15:48:31  warmerda
00132  * Fixed email address, trimmed log messages.
00133  *
00134  * Revision 1.63  2003/04/25 19:46:13  warmerda
00135  * added GDALDatasetRasterIO
00136  *
00137  * Revision 1.62  2003/03/18 06:01:03  warmerda
00138  * Added GDALFlushCache()
00139  *
00140  * Revision 1.61  2003/02/20 18:34:12  warmerda
00141  * added GDALGetRasterAccess()
00142  *
00143  * Revision 1.60  2003/01/27 21:55:52  warmerda
00144  * various documentation improvements
00145  *
00146  * Revision 1.59  2002/12/21 17:28:35  warmerda
00147  * actually, lets use 1.1.8.0
00148  *
00149  * Revision 1.58  2002/12/21 17:26:43  warmerda
00150  * updated version to 1.1.7.5
00151  *
00152  * Revision 1.57  2002/12/05 15:46:38  warmerda
00153  * added GDALReadTabFile()
00154  *
00155  * Revision 1.56  2002/11/23 18:07:41  warmerda
00156  * added DMD_CREATIONDATATYPES
00157  *
00158  * Revision 1.55  2002/10/24 14:18:29  warmerda
00159  * intermediate version update
00160  *
00161  * Revision 1.54  2002/09/11 14:17:38  warmerda
00162  * added C GDALSetDescription()
00163  *
00164  * Revision 1.53  2002/09/06 01:29:55  warmerda
00165  * added C entry points for GetAccess() and GetOpenDatasets()
00166  *
00167  * Revision 1.52  2002/09/04 06:52:35  warmerda
00168  * added GDALDestroyDriverManager
00169  *
00170  * Revision 1.51  2002/07/09 20:33:12  warmerda
00171  * expand tabs
00172  *
00173  * Revision 1.50  2002/06/12 21:13:27  warmerda
00174  * use metadata based driver info
00175  *
00176  * Revision 1.49  2002/05/28 18:55:46  warmerda
00177  * added GDALOpenShared() and GDALDumpOpenDatasets
00178  *
00179  * Revision 1.48  2002/05/14 21:38:32  warmerda
00180  * make INST_DATA overidable with binary patch
00181  *
00182  * Revision 1.47  2002/05/06 21:37:29  warmerda
00183  * added GDALGCPsToGeoTransform
00184  *
00185  * Revision 1.46  2002/04/24 16:25:04  warmerda
00186  * Ensure that GDAL{Read,Write}WorldFile() are exported on Windows.
00187  *
00188  * Revision 1.45  2002/04/19 12:22:05  dron
00189  * added GDALWriteWorldFile()
00190  *
00191  * Revision 1.44  2002/04/16 13:59:33  warmerda
00192  * added GDALVersionInfo
00193  *
00194  * Revision 1.43  2002/04/16 13:26:08  warmerda
00195  * upgrade to version 1.1.7
00196  */
00197 
00198 #ifndef GDAL_H_INCLUDED
00199 #define GDAL_H_INCLUDED
00200 
00207 #include "gdal_version.h"
00208 #include "cpl_port.h"
00209 #include "cpl_error.h"
00210 
00211 /* -------------------------------------------------------------------- */
00212 /*      Significant constants.                                          */
00213 /* -------------------------------------------------------------------- */
00214 
00215 CPL_C_START
00216 
00218 typedef enum {
00219     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,
00231     GDT_TypeCount = 12          /* maximum type # + 1 */
00232 } GDALDataType;
00233 
00234 int CPL_DLL CPL_STDCALL GDALGetDataTypeSize( GDALDataType );
00235 int CPL_DLL CPL_STDCALL GDALDataTypeIsComplex( GDALDataType );
00236 const char CPL_DLL * CPL_STDCALL GDALGetDataTypeName( GDALDataType );
00237 GDALDataType CPL_DLL CPL_STDCALL GDALGetDataTypeByName( const char * );
00238 GDALDataType CPL_DLL CPL_STDCALL GDALDataTypeUnion( GDALDataType, GDALDataType );
00239 
00241 typedef enum { GA_ReadOnly = 0,           GA_Update = 1
00244 } GDALAccess;
00245 
00247 typedef enum {   GF_Read = 0,  GF_Write = 1
00250 } GDALRWFlag;
00251 
00253 typedef enum
00254 {
00255     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
00273 } GDALColorInterp;
00274 
00276 const char CPL_DLL *GDALGetColorInterpretationName( GDALColorInterp );
00277 
00279 typedef enum 
00280 {                      GPI_Gray=0,  GPI_RGB=1, GPI_CMYK=2,     GPI_HLS=3
00285 } GDALPaletteInterp;
00286 
00288 const char CPL_DLL *GDALGetPaletteInterpretationName( GDALPaletteInterp );
00289 
00290 /* "well known" metadata items. */
00291 
00292 #define GDALMD_AREA_OR_POINT   "AREA_OR_POINT" 
00293 #  define GDALMD_AOP_AREA      "Area"
00294 #  define GDALMD_AOP_POINT     "Point"
00295 
00296 /* -------------------------------------------------------------------- */
00297 /*      GDAL Specific error codes.                                      */
00298 /*                                                                      */
00299 /*      error codes 100 to 299 reserved for GDAL.                       */
00300 /* -------------------------------------------------------------------- */
00301 #define CPLE_WrongFormat        200
00302 
00303 /* -------------------------------------------------------------------- */
00304 /*      Define handle types related to various internal classes.        */
00305 /* -------------------------------------------------------------------- */
00306 typedef void *GDALMajorObjectH;
00307 typedef void *GDALDatasetH;
00308 typedef void *GDALRasterBandH;
00309 typedef void *GDALDriverH;
00310 typedef void *GDALProjDefH;
00311 typedef void *GDALColorTableH;
00312 
00313 /* -------------------------------------------------------------------- */
00314 /*      Callback "progress" function.                                   */
00315 /* -------------------------------------------------------------------- */
00316 
00317 typedef int (CPL_STDCALL *GDALProgressFunc)(double,const char *, void *);
00318 int CPL_DLL CPL_STDCALL GDALDummyProgress( double, const char *, void *);
00319 int CPL_DLL CPL_STDCALL GDALTermProgress( double, const char *, void *);
00320 int CPL_DLL CPL_STDCALL GDALScaledProgress( double, const char *, void *);
00321 void CPL_DLL * CPL_STDCALL GDALCreateScaledProgress( double, double,
00322                                         GDALProgressFunc, void * );
00323 void CPL_DLL CPL_STDCALL GDALDestroyScaledProgress( void * );
00324 
00325 /* ==================================================================== */
00326 /*      Registration/driver related.                                    */
00327 /* ==================================================================== */
00328 
00329 typedef struct {
00330     char      *pszOptionName;
00331     char      *pszValueType;   /* "boolean", "int", "float", "string", 
00332                                   "string-select" */
00333     char      *pszDescription;
00334     char      **papszOptions;
00335 } GDALOptionDefinition;
00336 
00337 #define GDAL_DMD_LONGNAME "DMD_LONGNAME"
00338 #define GDAL_DMD_HELPTOPIC "DMD_HELPTOPIC"
00339 #define GDAL_DMD_MIMETYPE "DMD_MIMETYPE"
00340 #define GDAL_DMD_EXTENSION "DMD_EXTENSION"
00341 #define GDAL_DMD_CREATIONOPTIONLIST "DMD_CREATIONOPTIONLIST" 
00342 #define GDAL_DMD_CREATIONDATATYPES "DMD_CREATIONDATATYPES" 
00343 
00344 #define GDAL_DCAP_CREATE     "DCAP_CREATE"
00345 #define GDAL_DCAP_CREATECOPY "DCAP_CREATECOPY"
00346 
00347 void CPL_DLL CPL_STDCALL GDALAllRegister( void );
00348 
00349 GDALDatasetH CPL_DLL CPL_STDCALL GDALCreate( GDALDriverH hDriver,
00350                                  const char *, int, int, int, GDALDataType,
00351                                  char ** );
00352 GDALDatasetH CPL_DLL CPL_STDCALL
00353 GDALCreateCopy( GDALDriverH, const char *, GDALDatasetH,
00354                 int, char **, GDALProgressFunc, void * );
00355 
00356 GDALDatasetH CPL_DLL CPL_STDCALL
00357 GDALOpen( const char *pszFilename, GDALAccess eAccess );
00358 GDALDatasetH CPL_DLL CPL_STDCALL GDALOpenShared( const char *, GDALAccess );
00359 int          CPL_DLL CPL_STDCALL GDALDumpOpenDatasets( FILE * );
00360 
00361 GDALDriverH CPL_DLL CPL_STDCALL GDALGetDriverByName( const char * );
00362 int CPL_DLL         CPL_STDCALL GDALGetDriverCount();
00363 GDALDriverH CPL_DLL CPL_STDCALL GDALGetDriver( int );
00364 int         CPL_DLL CPL_STDCALL GDALRegisterDriver( GDALDriverH );
00365 void        CPL_DLL CPL_STDCALL GDALDeregisterDriver( GDALDriverH );
00366 void        CPL_DLL CPL_STDCALL GDALDestroyDriverManager( void );
00367 CPLErr      CPL_DLL CPL_STDCALL GDALDeleteDataset( GDALDriverH, const char * );
00368 
00369 /* The following are deprecated */
00370 const char CPL_DLL * CPL_STDCALL GDALGetDriverShortName( GDALDriverH );
00371 const char CPL_DLL * CPL_STDCALL GDALGetDriverLongName( GDALDriverH );
00372 const char CPL_DLL * CPL_STDCALL GDALGetDriverHelpTopic( GDALDriverH );
00373 const char CPL_DLL * CPL_STDCALL GDALGetDriverCreationOptionList( GDALDriverH );
00374 
00375 /* ==================================================================== */
00376 /*      GDAL_GCP                                                        */
00377 /* ==================================================================== */
00378 
00380 typedef struct
00381 {
00383     char        *pszId; 
00384 
00386     char        *pszInfo;
00387 
00389     double      dfGCPPixel;
00391     double      dfGCPLine;
00392 
00394     double      dfGCPX;
00395 
00397     double      dfGCPY;
00398 
00400     double      dfGCPZ;
00401 } GDAL_GCP;
00402 
00403 void CPL_DLL CPL_STDCALL GDALInitGCPs( int, GDAL_GCP * );
00404 void CPL_DLL CPL_STDCALL GDALDeinitGCPs( int, GDAL_GCP * );
00405 GDAL_GCP CPL_DLL * CPL_STDCALL GDALDuplicateGCPs( int, const GDAL_GCP * );
00406 
00407 int CPL_DLL CPL_STDCALL
00408 GDALGCPsToGeoTransform( int nGCPCount, const GDAL_GCP *pasGCPs, 
00409                         double *padfGeoTransform, int bApproxOK ); 
00410 int CPL_DLL CPL_STDCALL
00411 GDALInvGeoTransform( double *padfGeoTransformIn, 
00412                      double *padfInvGeoTransformOut );
00413 void CPL_DLL CPL_STDCALL GDALApplyGeoTransform( double *, double, double, 
00414                                                 double *, double * );
00415 
00416 /* ==================================================================== */
00417 /*      major objects (dataset, and, driver, drivermanager).            */
00418 /* ==================================================================== */
00419 
00420 char CPL_DLL  ** CPL_STDCALL GDALGetMetadata( GDALMajorObjectH, const char * );
00421 CPLErr CPL_DLL CPL_STDCALL GDALSetMetadata( GDALMajorObjectH, char **,
00422                                             const char * );
00423 const char CPL_DLL * CPL_STDCALL 
00424 GDALGetMetadataItem( GDALMajorObjectH, const char *, const char * );
00425 CPLErr CPL_DLL CPL_STDCALL
00426 GDALSetMetadataItem( GDALMajorObjectH, const char *, const char *,
00427                      const char * );
00428 const char CPL_DLL * CPL_STDCALL GDALGetDescription( GDALMajorObjectH );
00429 void CPL_DLL CPL_STDCALL GDALSetDescription( GDALMajorObjectH, const char * );
00430 
00431 /* ==================================================================== */
00432 /*      GDALDataset class ... normally this represents one file.        */
00433 /* ==================================================================== */
00434 
00435 GDALDriverH CPL_DLL CPL_STDCALL GDALGetDatasetDriver( GDALDatasetH );
00436 void CPL_DLL CPL_STDCALL   GDALClose( GDALDatasetH );
00437 int CPL_DLL CPL_STDCALL     GDALGetRasterXSize( GDALDatasetH );
00438 int CPL_DLL CPL_STDCALL     GDALGetRasterYSize( GDALDatasetH );
00439 int CPL_DLL CPL_STDCALL     GDALGetRasterCount( GDALDatasetH );
00440 GDALRasterBandH CPL_DLL CPL_STDCALL GDALGetRasterBand( GDALDatasetH, int );
00441 
00442 CPLErr CPL_DLL  CPL_STDCALL GDALAddBand( GDALDatasetH hDS, GDALDataType eType, 
00443                              char **papszOptions );
00444 
00445 CPLErr CPL_DLL CPL_STDCALL GDALDatasetRasterIO( 
00446     GDALDatasetH hDS, GDALRWFlag eRWFlag,
00447     int nDSXOff, int nDSYOff, int nDSXSize, int nDSYSize,
00448     void * pBuffer, int nBXSize, int nBYSize, GDALDataType eBDataType,
00449     int nBandCount, int *panBandCount, 
00450     int nPixelSpace, int nLineSpace, int nBandSpace);
00451 
00452 CPLErr CPL_DLL CPL_STDCALL GDALDatasetAdviseRead( GDALDatasetH hDS, 
00453     int nDSXOff, int nDSYOff, int nDSXSize, int nDSYSize,
00454     int nBXSize, int nBYSize, GDALDataType eBDataType,
00455     int nBandCount, int *panBandCount, char **papszOptions );
00456 
00457 const char CPL_DLL * CPL_STDCALL GDALGetProjectionRef( GDALDatasetH );
00458 CPLErr CPL_DLL CPL_STDCALL GDALSetProjection( GDALDatasetH, const char * );
00459 CPLErr CPL_DLL CPL_STDCALL GDALGetGeoTransform( GDALDatasetH, double * );
00460 CPLErr CPL_DLL CPL_STDCALL GDALSetGeoTransform( GDALDatasetH, double * );
00461 
00462 int CPL_DLL CPL_STDCALL  GDALGetGCPCount( GDALDatasetH );
00463 const char CPL_DLL * CPL_STDCALL GDALGetGCPProjection( GDALDatasetH );
00464 const GDAL_GCP CPL_DLL * CPL_STDCALL GDALGetGCPs( GDALDatasetH );
00465 CPLErr CPL_DLL CPL_STDCALL GDALSetGCPs( GDALDatasetH, int, const GDAL_GCP *,
00466                                         const char * );
00467 
00468 void CPL_DLL * CPL_STDCALL GDALGetInternalHandle( GDALDatasetH, const char * );
00469 int CPL_DLL CPL_STDCALL GDALReferenceDataset( GDALDatasetH );
00470 int CPL_DLL CPL_STDCALL GDALDereferenceDataset( GDALDatasetH );
00471 
00472 CPLErr CPL_DLL CPL_STDCALL
00473 GDALBuildOverviews( GDALDatasetH, const char *, int, int *,
00474                     int, int *, GDALProgressFunc, void * );
00475 void CPL_DLL CPL_STDCALL GDALGetOpenDatasets( GDALDatasetH ***hDS, int *pnCount );
00476 int CPL_DLL CPL_STDCALL GDALGetAccess( GDALDatasetH hDS );
00477 void CPL_DLL CPL_STDCALL GDALFlushCache( GDALDatasetH hDS );
00478 
00479 /* ==================================================================== */
00480 /*      GDALRasterBand ... one band/channel in a dataset.               */
00481 /* ==================================================================== */
00482 
00483 GDALDataType CPL_DLL CPL_STDCALL GDALGetRasterDataType( GDALRasterBandH );
00484 void CPL_DLL CPL_STDCALL 
00485 GDALGetBlockSize( GDALRasterBandH, int * pnXSize, int * pnYSize );
00486 
00487 CPLErr CPL_DLL CPL_STDCALL GDALRasterAdviseRead( GDALRasterBandH hRB, 
00488     int nDSXOff, int nDSYOff, int nDSXSize, int nDSYSize,
00489     int nBXSize, int nBYSize, GDALDataType eBDataType, char **papszOptions );
00490 
00491 CPLErr CPL_DLL CPL_STDCALL 
00492 GDALRasterIO( GDALRasterBandH hRBand, GDALRWFlag eRWFlag,
00493               int nDSXOff, int nDSYOff, int nDSXSize, int nDSYSize,
00494               void * pBuffer, int nBXSize, int nBYSize,GDALDataType eBDataType,
00495               int nPixelSpace, int nLineSpace );
00496 CPLErr CPL_DLL CPL_STDCALL GDALReadBlock( GDALRasterBandH, int, int, void * );
00497 CPLErr CPL_DLL CPL_STDCALL GDALWriteBlock( GDALRasterBandH, int, int, void * );
00498 int CPL_DLL CPL_STDCALL GDALGetRasterBandXSize( GDALRasterBandH );
00499 int CPL_DLL CPL_STDCALL GDALGetRasterBandYSize( GDALRasterBandH );
00500 char CPL_DLL ** CPL_STDCALL GDALGetRasterMetadata( GDALRasterBandH );
00501 GDALAccess CPL_DLL CPL_STDCALL GDALGetRasterAccess( GDALRasterBandH );
00502 int CPL_DLL CPL_STDCALL GDALGetBandNumber( GDALRasterBandH );
00503 GDALDatasetH CPL_DLL CPL_STDCALL GDALGetBandDataset( GDALRasterBandH );
00504 
00505 GDALColorInterp CPL_DLL CPL_STDCALL
00506 GDALGetRasterColorInterpretation( GDALRasterBandH );
00507 CPLErr CPL_DLL CPL_STDCALL 
00508 GDALSetRasterColorInterpretation( GDALRasterBandH, GDALColorInterp );
00509 GDALColorTableH CPL_DLL CPL_STDCALL GDALGetRasterColorTable( GDALRasterBandH );
00510 CPLErr CPL_DLL CPL_STDCALL GDALSetRasterColorTable( GDALRasterBandH, GDALColorTableH );
00511 int CPL_DLL CPL_STDCALL GDALHasArbitraryOverviews( GDALRasterBandH );
00512 int CPL_DLL CPL_STDCALL GDALGetOverviewCount( GDALRasterBandH );
00513 GDALRasterBandH CPL_DLL CPL_STDCALL GDALGetOverview( GDALRasterBandH, int );
00514 double CPL_DLL CPL_STDCALL GDALGetRasterNoDataValue( GDALRasterBandH, int * );
00515 CPLErr CPL_DLL CPL_STDCALL GDALSetRasterNoDataValue( GDALRasterBandH, double );
00516 char CPL_DLL ** CPL_STDCALL GDALGetRasterCategoryNames( GDALRasterBandH );
00517 CPLErr CPL_DLL CPL_STDCALL GDALSetRasterCategoryNames( GDALRasterBandH, char ** );
00518 double CPL_DLL CPL_STDCALL GDALGetRasterMinimum( GDALRasterBandH, int *pbSuccess );
00519 double CPL_DLL CPL_STDCALL GDALGetRasterMaximum( GDALRasterBandH, int *pbSuccess );
00520 CPLErr CPL_DLL CPL_STDCALL GDALGetRasterStatistics( 
00521     GDALRasterBandH, int bApproxOK, int bForce, 
00522     double *pdfMin, double *pdfMax, double *pdfMean, double *pdfStdDev );
00523 const char CPL_DLL * CPL_STDCALL GDALGetRasterUnitType( GDALRasterBandH );
00524 double CPL_DLL CPL_STDCALL GDALGetRasterOffset( GDALRasterBandH, int *pbSuccess );
00525 CPLErr CPL_DLL CPL_STDCALL GDALSetRasterOffset( GDALRasterBandH hBand, double dfNewOffset);
00526 double CPL_DLL CPL_STDCALL GDALGetRasterScale( GDALRasterBandH, int *pbSuccess );
00527 CPLErr CPL_DLL CPL_STDCALL GDALSetRasterScale( GDALRasterBandH hBand, double dfNewOffset );
00528 void CPL_DLL CPL_STDCALL 
00529 GDALComputeRasterMinMax( GDALRasterBandH hBand, int bApproxOK,
00530                          double adfMinMax[2] );
00531 CPLErr CPL_DLL CPL_STDCALL GDALFlushRasterCache( GDALRasterBandH hBand );
00532 CPLErr CPL_DLL CPL_STDCALL GDALGetRasterHistogram( GDALRasterBandH hBand,
00533                                        double dfMin, double dfMax,
00534                                        int nBuckets, int *panHistogram,
00535                                        int bIncludeOutOfRange, int bApproxOK,
00536                                        GDALProgressFunc pfnProgress,
00537                                        void * pProgressData );
00538 CPLErr CPL_DLL CPL_STDCALL GDALGetDefaultHistogram( GDALRasterBandH hBand,
00539                                        double *pdfMin, double *pdfMax,
00540                                        int *pnBuckets, int **ppanHistogram,
00541                                        int bForce,
00542                                        GDALProgressFunc pfnProgress,
00543                                        void * pProgressData );
00544 CPLErr CPL_DLL CPL_STDCALL GDALSetDefaultHistogram( GDALRasterBandH hBand,
00545                                        double dfMin, double dfMax,
00546                                        int nBuckets, int *panHistogram );
00547 int CPL_DLL CPL_STDCALL
00548 GDALGetRandomRasterSample( GDALRasterBandH, int, float * );
00549 GDALRasterBandH CPL_DLL CPL_STDCALL
00550 GDALGetRasterSampleOverview( GDALRasterBandH, int );
00551 CPLErr CPL_DLL CPL_STDCALL GDALFillRaster( GDALRasterBandH hBand,
00552                           double dfRealValue, double dfImaginaryValue );
00553 CPLErr CPL_DLL CPL_STDCALL
00554 GDALComputeBandStats( GDALRasterBandH hBand, int nSampleStep, 
00555                              double *pdfMean, double *pdfStdDev, 
00556                              GDALProgressFunc pfnProgress,
00557                              void *pProgressData );
00558 CPLErr CPL_DLL  GDALOverviewMagnitudeCorrection( GDALRasterBandH hBaseBand, 
00559                                         int nOverviewCount, 
00560                                         GDALRasterBandH *pahOverviews, 
00561                                         GDALProgressFunc pfnProgress, 
00562                                         void *pProgressData );
00563 
00564 /* -------------------------------------------------------------------- */
00565 /*      Helper functions.                                               */
00566 /* -------------------------------------------------------------------- */
00567 int CPL_DLL CPL_STDCALL GDALGeneralCmdLineProcessor( int nArgc, char ***ppapszArgv, 
00568                                          int nOptions );
00569 void CPL_DLL CPL_STDCALL GDALSwapWords( void *pData, int nWordSize, int nWordCount,
00570                             int nWordSkip );
00571 void CPL_DLL CPL_STDCALL 
00572     GDALCopyWords( void * pSrcData, GDALDataType eSrcType, int nSrcPixelOffset,
00573                    void * pDstData, GDALDataType eDstType, int nDstPixelOffset,
00574                    int nWordCount );
00575 
00576 int CPL_DLL CPL_STDCALL GDALReadWorldFile( const char *pszBaseFilename, 
00577                        const char *pszExtension, 
00578                        double * padfGeoTransform );
00579 int CPL_DLL CPL_STDCALL GDALWriteWorldFile( const char *pszBaseFilename, 
00580                        const char *pszExtension, 
00581                        double * padfGeoTransform );
00582 int CPL_DLL CPL_STDCALL GDALReadTabFile( const char *pszBaseFilename, 
00583                              double *padfGeoTransform, char **ppszWKT,
00584                              int *pnGCPCount, GDAL_GCP **ppasGCPs );
00585 
00586 const char CPL_DLL * CPL_STDCALL GDALDecToDMS( double, const char *, int );
00587 double CPL_DLL CPL_STDCALL GDALPackedDMSToDec( double );
00588 double CPL_DLL CPL_STDCALL GDALDecToPackedDMS( double );
00589 
00590 const char CPL_DLL * CPL_STDCALL GDALVersionInfo( const char * );
00591 
00592 typedef struct { 
00593     double      dfLINE_OFF;
00594     double      dfSAMP_OFF;
00595     double      dfLAT_OFF;
00596     double      dfLONG_OFF;
00597     double      dfHEIGHT_OFF;
00598 
00599     double      dfLINE_SCALE;
00600     double      dfSAMP_SCALE;
00601     double      dfLAT_SCALE;
00602     double      dfLONG_SCALE;
00603     double      dfHEIGHT_SCALE;
00604 
00605     double      adfLINE_NUM_COEFF[20];
00606     double      adfLINE_DEN_COEFF[20];
00607     double      adfSAMP_NUM_COEFF[20];
00608     double      adfSAMP_DEN_COEFF[20];
00609     
00610     double      dfMIN_LONG;
00611     double      dfMIN_LAT;
00612     double      dfMAX_LONG;
00613     double      dfMAX_LAT;
00614 
00615 } GDALRPCInfo;
00616 
00617 int CPL_DLL CPL_STDCALL GDALExtractRPCInfo( char **, GDALRPCInfo * );
00618 
00619 /* ==================================================================== */
00620 /*      Color tables.                                                   */
00621 /* ==================================================================== */
00623 typedef struct
00624 {
00626     short      c1;      
00627 
00629     short      c2;      
00630 
00632     short      c3;      
00633 
00635     short      c4;      
00636 } GDALColorEntry;
00637 
00638 GDALColorTableH CPL_DLL CPL_STDCALL GDALCreateColorTable( GDALPaletteInterp );
00639 void CPL_DLL CPL_STDCALL GDALDestroyColorTable( GDALColorTableH );
00640 GDALColorTableH CPL_DLL CPL_STDCALL GDALCloneColorTable( GDALColorTableH );
00641 GDALPaletteInterp CPL_DLL CPL_STDCALL GDALGetPaletteInterpretation( GDALColorTableH );
00642 int CPL_DLL CPL_STDCALL GDALGetColorEntryCount( GDALColorTableH );
00643 const GDALColorEntry CPL_DLL * CPL_STDCALL GDALGetColorEntry( GDALColorTableH, int );
00644 int CPL_DLL CPL_STDCALL GDALGetColorEntryAsRGB( GDALColorTableH, int, GDALColorEntry *);
00645 void CPL_DLL CPL_STDCALL GDALSetColorEntry( GDALColorTableH, int, const GDALColorEntry * );
00646 
00647 /* ==================================================================== */
00648 /*      GDAL Cache Management                                           */
00649 /* ==================================================================== */
00650 
00651 void CPL_DLL CPL_STDCALL GDALSetCacheMax( int nBytes );
00652 int CPL_DLL CPL_STDCALL GDALGetCacheMax();
00653 int CPL_DLL CPL_STDCALL GDALGetCacheUsed();
00654 int CPL_DLL CPL_STDCALL GDALFlushCacheBlock();
00655 
00656 CPL_C_END
00657 
00658 #endif /* ndef GDAL_H_INCLUDED */

Generated on Mon Aug 29 04:05:35 2005 for GDAL by doxygen 1.3.6