00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044
00045
00046
00047
00048
00049
00050
00051
00052
00053
00054
00055
00056
00057
00058
00059
00060
00061
00062
00063
00064
00065
00066
00067
00068
00069
00070
00071
00072
00073
00074
00075
00076
00077
00078
00079
00080
00081
00082
00083
00084
00085
00086
00087
00088
00089
00090
00091
00092
00093
00094
00095
00096
00097
00098
00099
00100
00101
00102
00103
00104
00105
00106
00107
00108
00109
00110
00111
00112
00113
00114
00115
00116
00117
00118
00119
00120
00121
00122
00123
00124
00125 #ifndef GDAL_H_INCLUDED
00126 #define GDAL_H_INCLUDED
00127
00134 #include "gdal_version.h"
00135 #include "cpl_port.h"
00136 #include "cpl_error.h"
00137
00138
00139
00140
00141
00142 CPL_C_START
00143
00145 typedef enum {
00146 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,
00158 GDT_TypeCount = 12
00159 } GDALDataType;
00160
00161 int CPL_DLL CPL_STDCALL GDALGetDataTypeSize( GDALDataType );
00162 int CPL_DLL CPL_STDCALL GDALDataTypeIsComplex( GDALDataType );
00163 const char CPL_DLL * CPL_STDCALL GDALGetDataTypeName( GDALDataType );
00164 GDALDataType CPL_DLL CPL_STDCALL GDALGetDataTypeByName( const char * );
00165 GDALDataType CPL_DLL CPL_STDCALL GDALDataTypeUnion( GDALDataType, GDALDataType );
00166
00168 typedef enum { GA_ReadOnly = 0, GA_Update = 1
00171 } GDALAccess;
00172
00174 typedef enum { GF_Read = 0, GF_Write = 1
00177 } GDALRWFlag;
00178
00180 typedef enum
00181 {
00182 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
00200 } GDALColorInterp;
00201
00203 const char CPL_DLL *GDALGetColorInterpretationName( GDALColorInterp );
00204
00206 typedef enum
00207 { GPI_Gray=0, GPI_RGB=1, GPI_CMYK=2, GPI_HLS=3
00212 } GDALPaletteInterp;
00213
00215 const char CPL_DLL *GDALGetPaletteInterpretationName( GDALPaletteInterp );
00216
00217
00218
00219 #define GDALMD_AREA_OR_POINT "AREA_OR_POINT"
00220 # define GDALMD_AOP_AREA "Area"
00221 # define GDALMD_AOP_POINT "Point"
00222
00223
00224
00225
00226
00227
00228 #define CPLE_WrongFormat 200
00229
00230
00231
00232
00233 typedef void *GDALMajorObjectH;
00234 typedef void *GDALDatasetH;
00235 typedef void *GDALRasterBandH;
00236 typedef void *GDALDriverH;
00237 typedef void *GDALProjDefH;
00238 typedef void *GDALColorTableH;
00239 typedef void *GDALRasterAttributeTableH;
00240
00241
00242
00243
00244
00245 typedef int (CPL_STDCALL *GDALProgressFunc)(double,const char *, void *);
00246 int CPL_DLL CPL_STDCALL GDALDummyProgress( double, const char *, void *);
00247 int CPL_DLL CPL_STDCALL GDALTermProgress( double, const char *, void *);
00248 int CPL_DLL CPL_STDCALL GDALScaledProgress( double, const char *, void *);
00249 void CPL_DLL * CPL_STDCALL GDALCreateScaledProgress( double, double,
00250 GDALProgressFunc, void * );
00251 void CPL_DLL CPL_STDCALL GDALDestroyScaledProgress( void * );
00252
00253
00254
00255
00256
00257 typedef struct {
00258 char *pszOptionName;
00259 char *pszValueType;
00260
00261 char *pszDescription;
00262 char **papszOptions;
00263 } GDALOptionDefinition;
00264
00265 #define GDAL_DMD_LONGNAME "DMD_LONGNAME"
00266 #define GDAL_DMD_HELPTOPIC "DMD_HELPTOPIC"
00267 #define GDAL_DMD_MIMETYPE "DMD_MIMETYPE"
00268 #define GDAL_DMD_EXTENSION "DMD_EXTENSION"
00269 #define GDAL_DMD_CREATIONOPTIONLIST "DMD_CREATIONOPTIONLIST"
00270 #define GDAL_DMD_CREATIONDATATYPES "DMD_CREATIONDATATYPES"
00271
00272 #define GDAL_DCAP_CREATE "DCAP_CREATE"
00273 #define GDAL_DCAP_CREATECOPY "DCAP_CREATECOPY"
00274
00275 void CPL_DLL CPL_STDCALL GDALAllRegister( void );
00276
00277 GDALDatasetH CPL_DLL CPL_STDCALL GDALCreate( GDALDriverH hDriver,
00278 const char *, int, int, int, GDALDataType,
00279 char ** );
00280 GDALDatasetH CPL_DLL CPL_STDCALL
00281 GDALCreateCopy( GDALDriverH, const char *, GDALDatasetH,
00282 int, char **, GDALProgressFunc, void * );
00283
00284 GDALDatasetH CPL_DLL CPL_STDCALL
00285 GDALOpen( const char *pszFilename, GDALAccess eAccess );
00286 GDALDatasetH CPL_DLL CPL_STDCALL GDALOpenShared( const char *, GDALAccess );
00287 int CPL_DLL CPL_STDCALL GDALDumpOpenDatasets( FILE * );
00288
00289 GDALDriverH CPL_DLL CPL_STDCALL GDALGetDriverByName( const char * );
00290 int CPL_DLL CPL_STDCALL GDALGetDriverCount( void );
00291 GDALDriverH CPL_DLL CPL_STDCALL GDALGetDriver( int );
00292 int CPL_DLL CPL_STDCALL GDALRegisterDriver( GDALDriverH );
00293 void CPL_DLL CPL_STDCALL GDALDeregisterDriver( GDALDriverH );
00294 void CPL_DLL CPL_STDCALL GDALDestroyDriverManager( void );
00295 CPLErr CPL_DLL CPL_STDCALL GDALDeleteDataset( GDALDriverH, const char * );
00296
00297
00298 const char CPL_DLL * CPL_STDCALL GDALGetDriverShortName( GDALDriverH );
00299 const char CPL_DLL * CPL_STDCALL GDALGetDriverLongName( GDALDriverH );
00300 const char CPL_DLL * CPL_STDCALL GDALGetDriverHelpTopic( GDALDriverH );
00301 const char CPL_DLL * CPL_STDCALL GDALGetDriverCreationOptionList( GDALDriverH );
00302
00303
00304
00305
00306
00308 typedef struct
00309 {
00311 char *pszId;
00312
00314 char *pszInfo;
00315
00317 double dfGCPPixel;
00319 double dfGCPLine;
00320
00322 double dfGCPX;
00323
00325 double dfGCPY;
00326
00328 double dfGCPZ;
00329 } GDAL_GCP;
00330
00331 void CPL_DLL CPL_STDCALL GDALInitGCPs( int, GDAL_GCP * );
00332 void CPL_DLL CPL_STDCALL GDALDeinitGCPs( int, GDAL_GCP * );
00333 GDAL_GCP CPL_DLL * CPL_STDCALL GDALDuplicateGCPs( int, const GDAL_GCP * );
00334
00335 int CPL_DLL CPL_STDCALL
00336 GDALGCPsToGeoTransform( int nGCPCount, const GDAL_GCP *pasGCPs,
00337 double *padfGeoTransform, int bApproxOK );
00338 int CPL_DLL CPL_STDCALL
00339 GDALInvGeoTransform( double *padfGeoTransformIn,
00340 double *padfInvGeoTransformOut );
00341 void CPL_DLL CPL_STDCALL GDALApplyGeoTransform( double *, double, double,
00342 double *, double * );
00343
00344
00345
00346
00347
00348 char CPL_DLL ** CPL_STDCALL GDALGetMetadata( GDALMajorObjectH, const char * );
00349 CPLErr CPL_DLL CPL_STDCALL GDALSetMetadata( GDALMajorObjectH, char **,
00350 const char * );
00351 const char CPL_DLL * CPL_STDCALL
00352 GDALGetMetadataItem( GDALMajorObjectH, const char *, const char * );
00353 CPLErr CPL_DLL CPL_STDCALL
00354 GDALSetMetadataItem( GDALMajorObjectH, const char *, const char *,
00355 const char * );
00356 const char CPL_DLL * CPL_STDCALL GDALGetDescription( GDALMajorObjectH );
00357 void CPL_DLL CPL_STDCALL GDALSetDescription( GDALMajorObjectH, const char * );
00358
00359
00360
00361
00362
00363 GDALDriverH CPL_DLL CPL_STDCALL GDALGetDatasetDriver( GDALDatasetH );
00364 void CPL_DLL CPL_STDCALL GDALClose( GDALDatasetH );
00365 int CPL_DLL CPL_STDCALL GDALGetRasterXSize( GDALDatasetH );
00366 int CPL_DLL CPL_STDCALL GDALGetRasterYSize( GDALDatasetH );
00367 int CPL_DLL CPL_STDCALL GDALGetRasterCount( GDALDatasetH );
00368 GDALRasterBandH CPL_DLL CPL_STDCALL GDALGetRasterBand( GDALDatasetH, int );
00369
00370 CPLErr CPL_DLL CPL_STDCALL GDALAddBand( GDALDatasetH hDS, GDALDataType eType,
00371 char **papszOptions );
00372
00373 CPLErr CPL_DLL CPL_STDCALL GDALDatasetRasterIO(
00374 GDALDatasetH hDS, GDALRWFlag eRWFlag,
00375 int nDSXOff, int nDSYOff, int nDSXSize, int nDSYSize,
00376 void * pBuffer, int nBXSize, int nBYSize, GDALDataType eBDataType,
00377 int nBandCount, int *panBandCount,
00378 int nPixelSpace, int nLineSpace, int nBandSpace);
00379
00380 CPLErr CPL_DLL CPL_STDCALL GDALDatasetAdviseRead( GDALDatasetH hDS,
00381 int nDSXOff, int nDSYOff, int nDSXSize, int nDSYSize,
00382 int nBXSize, int nBYSize, GDALDataType eBDataType,
00383 int nBandCount, int *panBandCount, char **papszOptions );
00384
00385 const char CPL_DLL * CPL_STDCALL GDALGetProjectionRef( GDALDatasetH );
00386 CPLErr CPL_DLL CPL_STDCALL GDALSetProjection( GDALDatasetH, const char * );
00387 CPLErr CPL_DLL CPL_STDCALL GDALGetGeoTransform( GDALDatasetH, double * );
00388 CPLErr CPL_DLL CPL_STDCALL GDALSetGeoTransform( GDALDatasetH, double * );
00389
00390 int CPL_DLL CPL_STDCALL GDALGetGCPCount( GDALDatasetH );
00391 const char CPL_DLL * CPL_STDCALL GDALGetGCPProjection( GDALDatasetH );
00392 const GDAL_GCP CPL_DLL * CPL_STDCALL GDALGetGCPs( GDALDatasetH );
00393 CPLErr CPL_DLL CPL_STDCALL GDALSetGCPs( GDALDatasetH, int, const GDAL_GCP *,
00394 const char * );
00395
00396 void CPL_DLL * CPL_STDCALL GDALGetInternalHandle( GDALDatasetH, const char * );
00397 int CPL_DLL CPL_STDCALL GDALReferenceDataset( GDALDatasetH );
00398 int CPL_DLL CPL_STDCALL GDALDereferenceDataset( GDALDatasetH );
00399
00400 CPLErr CPL_DLL CPL_STDCALL
00401 GDALBuildOverviews( GDALDatasetH, const char *, int, int *,
00402 int, int *, GDALProgressFunc, void * );
00403 void CPL_DLL CPL_STDCALL GDALGetOpenDatasets( GDALDatasetH ***hDS, int *pnCount );
00404 int CPL_DLL CPL_STDCALL GDALGetAccess( GDALDatasetH hDS );
00405 void CPL_DLL CPL_STDCALL GDALFlushCache( GDALDatasetH hDS );
00406
00407
00408
00409
00410
00415 #define SRCVAL(papoSource, eSrcType, ii) \
00416 (eSrcType == GDT_Byte ? \
00417 ((char *)papoSource)[ii] : \
00418 (eSrcType == GDT_Float32 ? \
00419 ((float *)papoSource)[ii] : \
00420 (eSrcType == GDT_Float64 ? \
00421 ((double *)papoSource)[ii] : \
00422 (eSrcType == GDT_Int32 ? \
00423 ((GInt32 *)papoSource)[ii] : \
00424 (eSrcType == GDT_UInt16 ? \
00425 ((GUInt16 *)papoSource)[ii] : \
00426 (eSrcType == GDT_Int16 ? \
00427 ((GInt16 *)papoSource)[ii] : \
00428 (eSrcType == GDT_UInt32 ? \
00429 ((GUInt32 *)papoSource)[ii] : \
00430 (eSrcType == GDT_CInt16 ? \
00431 ((GInt16 *)papoSource)[ii * 2] : \
00432 (eSrcType == GDT_CInt32 ? \
00433 ((GInt32 *)papoSource)[ii * 2] : \
00434 (eSrcType == GDT_CFloat32 ? \
00435 ((float *)papoSource)[ii * 2] : \
00436 (eSrcType == GDT_CFloat64 ? \
00437 ((double *)papoSource)[ii * 2] : 0)))))))))))
00438
00439 typedef CPLErr
00440 (*GDALDerivedPixelFunc)(void **papoSources, int nSources, void *pData,
00441 int nBufXSize, int nBufYSize,
00442 GDALDataType eSrcType, GDALDataType eBufType,
00443 int nPixelSpace, int nLineSpace);
00444
00445 GDALDataType CPL_DLL CPL_STDCALL GDALGetRasterDataType( GDALRasterBandH );
00446 void CPL_DLL CPL_STDCALL
00447 GDALGetBlockSize( GDALRasterBandH, int * pnXSize, int * pnYSize );
00448
00449 CPLErr CPL_DLL CPL_STDCALL GDALRasterAdviseRead( GDALRasterBandH hRB,
00450 int nDSXOff, int nDSYOff, int nDSXSize, int nDSYSize,
00451 int nBXSize, int nBYSize, GDALDataType eBDataType, char **papszOptions );
00452
00453 CPLErr CPL_DLL CPL_STDCALL
00454 GDALRasterIO( GDALRasterBandH hRBand, GDALRWFlag eRWFlag,
00455 int nDSXOff, int nDSYOff, int nDSXSize, int nDSYSize,
00456 void * pBuffer, int nBXSize, int nBYSize,GDALDataType eBDataType,
00457 int nPixelSpace, int nLineSpace );
00458 CPLErr CPL_DLL CPL_STDCALL GDALReadBlock( GDALRasterBandH, int, int, void * );
00459 CPLErr CPL_DLL CPL_STDCALL GDALWriteBlock( GDALRasterBandH, int, int, void * );
00460 int CPL_DLL CPL_STDCALL GDALGetRasterBandXSize( GDALRasterBandH );
00461 int CPL_DLL CPL_STDCALL GDALGetRasterBandYSize( GDALRasterBandH );
00462 char CPL_DLL ** CPL_STDCALL GDALGetRasterMetadata( GDALRasterBandH );
00463 GDALAccess CPL_DLL CPL_STDCALL GDALGetRasterAccess( GDALRasterBandH );
00464 int CPL_DLL CPL_STDCALL GDALGetBandNumber( GDALRasterBandH );
00465 GDALDatasetH CPL_DLL CPL_STDCALL GDALGetBandDataset( GDALRasterBandH );
00466
00467 GDALColorInterp CPL_DLL CPL_STDCALL
00468 GDALGetRasterColorInterpretation( GDALRasterBandH );
00469 CPLErr CPL_DLL CPL_STDCALL
00470 GDALSetRasterColorInterpretation( GDALRasterBandH, GDALColorInterp );
00471 GDALColorTableH CPL_DLL CPL_STDCALL GDALGetRasterColorTable( GDALRasterBandH );
00472 CPLErr CPL_DLL CPL_STDCALL GDALSetRasterColorTable( GDALRasterBandH, GDALColorTableH );
00473 int CPL_DLL CPL_STDCALL GDALHasArbitraryOverviews( GDALRasterBandH );
00474 int CPL_DLL CPL_STDCALL GDALGetOverviewCount( GDALRasterBandH );
00475 GDALRasterBandH CPL_DLL CPL_STDCALL GDALGetOverview( GDALRasterBandH, int );
00476 double CPL_DLL CPL_STDCALL GDALGetRasterNoDataValue( GDALRasterBandH, int * );
00477 CPLErr CPL_DLL CPL_STDCALL GDALSetRasterNoDataValue( GDALRasterBandH, double );
00478 char CPL_DLL ** CPL_STDCALL GDALGetRasterCategoryNames( GDALRasterBandH );
00479 CPLErr CPL_DLL CPL_STDCALL GDALSetRasterCategoryNames( GDALRasterBandH, char ** );
00480 double CPL_DLL CPL_STDCALL GDALGetRasterMinimum( GDALRasterBandH, int *pbSuccess );
00481 double CPL_DLL CPL_STDCALL GDALGetRasterMaximum( GDALRasterBandH, int *pbSuccess );
00482 CPLErr CPL_DLL CPL_STDCALL GDALGetRasterStatistics(
00483 GDALRasterBandH, int bApproxOK, int bForce,
00484 double *pdfMin, double *pdfMax, double *pdfMean, double *pdfStdDev );
00485 const char CPL_DLL * CPL_STDCALL GDALGetRasterUnitType( GDALRasterBandH );
00486 double CPL_DLL CPL_STDCALL GDALGetRasterOffset( GDALRasterBandH, int *pbSuccess );
00487 CPLErr CPL_DLL CPL_STDCALL GDALSetRasterOffset( GDALRasterBandH hBand, double dfNewOffset);
00488 double CPL_DLL CPL_STDCALL GDALGetRasterScale( GDALRasterBandH, int *pbSuccess );
00489 CPLErr CPL_DLL CPL_STDCALL GDALSetRasterScale( GDALRasterBandH hBand, double dfNewOffset );
00490 void CPL_DLL CPL_STDCALL
00491 GDALComputeRasterMinMax( GDALRasterBandH hBand, int bApproxOK,
00492 double adfMinMax[2] );
00493 CPLErr CPL_DLL CPL_STDCALL GDALFlushRasterCache( GDALRasterBandH hBand );
00494 CPLErr CPL_DLL CPL_STDCALL GDALGetRasterHistogram( GDALRasterBandH hBand,
00495 double dfMin, double dfMax,
00496 int nBuckets, int *panHistogram,
00497 int bIncludeOutOfRange, int bApproxOK,
00498 GDALProgressFunc pfnProgress,
00499 void * pProgressData );
00500 CPLErr CPL_DLL CPL_STDCALL GDALGetDefaultHistogram( GDALRasterBandH hBand,
00501 double *pdfMin, double *pdfMax,
00502 int *pnBuckets, int **ppanHistogram,
00503 int bForce,
00504 GDALProgressFunc pfnProgress,
00505 void * pProgressData );
00506 CPLErr CPL_DLL CPL_STDCALL GDALSetDefaultHistogram( GDALRasterBandH hBand,
00507 double dfMin, double dfMax,
00508 int nBuckets, int *panHistogram );
00509 int CPL_DLL CPL_STDCALL
00510 GDALGetRandomRasterSample( GDALRasterBandH, int, float * );
00511 GDALRasterBandH CPL_DLL CPL_STDCALL
00512 GDALGetRasterSampleOverview( GDALRasterBandH, int );
00513 CPLErr CPL_DLL CPL_STDCALL GDALFillRaster( GDALRasterBandH hBand,
00514 double dfRealValue, double dfImaginaryValue );
00515 CPLErr CPL_DLL CPL_STDCALL
00516 GDALComputeBandStats( GDALRasterBandH hBand, int nSampleStep,
00517 double *pdfMean, double *pdfStdDev,
00518 GDALProgressFunc pfnProgress,
00519 void *pProgressData );
00520 CPLErr CPL_DLL GDALOverviewMagnitudeCorrection( GDALRasterBandH hBaseBand,
00521 int nOverviewCount,
00522 GDALRasterBandH *pahOverviews,
00523 GDALProgressFunc pfnProgress,
00524 void *pProgressData );
00525
00526 GDALRasterAttributeTableH CPL_DLL CPL_STDCALL GDALGetDefaultRAT(
00527 GDALRasterBandH hBand );
00528 CPLErr CPL_DLL CPL_STDCALL GDALSetDefaultRAT( GDALRasterBandH,
00529 GDALRasterAttributeTableH );
00530 CPLErr CPL_DLL CPL_STDCALL GDALAddDerivedBandPixelFunc( const char *pszName,
00531 GDALDerivedPixelFunc pfnPixelFunc );
00532
00533
00534
00535
00536 int CPL_DLL CPL_STDCALL GDALGeneralCmdLineProcessor( int nArgc, char ***ppapszArgv,
00537 int nOptions );
00538 void CPL_DLL CPL_STDCALL GDALSwapWords( void *pData, int nWordSize, int nWordCount,
00539 int nWordSkip );
00540 void CPL_DLL CPL_STDCALL
00541 GDALCopyWords( void * pSrcData, GDALDataType eSrcType, int nSrcPixelOffset,
00542 void * pDstData, GDALDataType eDstType, int nDstPixelOffset,
00543 int nWordCount );
00544
00545 int CPL_DLL CPL_STDCALL GDALReadWorldFile( const char *pszBaseFilename,
00546 const char *pszExtension,
00547 double * padfGeoTransform );
00548 int CPL_DLL CPL_STDCALL GDALWriteWorldFile( const char *pszBaseFilename,
00549 const char *pszExtension,
00550 double * padfGeoTransform );
00551 int CPL_DLL CPL_STDCALL GDALReadTabFile( const char *pszBaseFilename,
00552 double *padfGeoTransform, char **ppszWKT,
00553 int *pnGCPCount, GDAL_GCP **ppasGCPs );
00554
00555 const char CPL_DLL * CPL_STDCALL GDALDecToDMS( double, const char *, int );
00556 double CPL_DLL CPL_STDCALL GDALPackedDMSToDec( double );
00557 double CPL_DLL CPL_STDCALL GDALDecToPackedDMS( double );
00558
00559 const char CPL_DLL * CPL_STDCALL GDALVersionInfo( const char * );
00560
00561 typedef struct {
00562 double dfLINE_OFF;
00563 double dfSAMP_OFF;
00564 double dfLAT_OFF;
00565 double dfLONG_OFF;
00566 double dfHEIGHT_OFF;
00567
00568 double dfLINE_SCALE;
00569 double dfSAMP_SCALE;
00570 double dfLAT_SCALE;
00571 double dfLONG_SCALE;
00572 double dfHEIGHT_SCALE;
00573
00574 double adfLINE_NUM_COEFF[20];
00575 double adfLINE_DEN_COEFF[20];
00576 double adfSAMP_NUM_COEFF[20];
00577 double adfSAMP_DEN_COEFF[20];
00578
00579 double dfMIN_LONG;
00580 double dfMIN_LAT;
00581 double dfMAX_LONG;
00582 double dfMAX_LAT;
00583
00584 } GDALRPCInfo;
00585
00586 int CPL_DLL CPL_STDCALL GDALExtractRPCInfo( char **, GDALRPCInfo * );
00587
00588
00589
00590
00592 typedef struct
00593 {
00595 short c1;
00596
00598 short c2;
00599
00601 short c3;
00602
00604 short c4;
00605 } GDALColorEntry;
00606
00607 GDALColorTableH CPL_DLL CPL_STDCALL GDALCreateColorTable( GDALPaletteInterp );
00608 void CPL_DLL CPL_STDCALL GDALDestroyColorTable( GDALColorTableH );
00609 GDALColorTableH CPL_DLL CPL_STDCALL GDALCloneColorTable( GDALColorTableH );
00610 GDALPaletteInterp CPL_DLL CPL_STDCALL GDALGetPaletteInterpretation( GDALColorTableH );
00611 int CPL_DLL CPL_STDCALL GDALGetColorEntryCount( GDALColorTableH );
00612 const GDALColorEntry CPL_DLL * CPL_STDCALL GDALGetColorEntry( GDALColorTableH, int );
00613 int CPL_DLL CPL_STDCALL GDALGetColorEntryAsRGB( GDALColorTableH, int, GDALColorEntry *);
00614 void CPL_DLL CPL_STDCALL GDALSetColorEntry( GDALColorTableH, int, const GDALColorEntry * );
00615
00616
00617
00618
00619
00620 typedef enum { GFT_Integer , GFT_Real, GFT_String
00624 } GDALRATFieldType;
00625
00626 typedef enum { GFU_Generic = 0, GFU_PixelCount = 1, GFU_Name = 2, GFU_Min = 3, GFU_Max = 4, GFU_MinMax = 5, GFU_Red = 6, GFU_Green = 7, GFU_Blue = 8, GFU_Alpha = 9, GFU_RedMin = 10, GFU_GreenMin = 11, GFU_BlueMin = 12, GFU_AlphaMin = 13, GFU_RedMax = 14, GFU_GreenMax = 15, GFU_BlueMax = 16, GFU_AlphaMax = 17, GFU_MaxCount
00646 } GDALRATFieldUsage;
00647
00648 GDALRasterAttributeTableH CPL_DLL CPL_STDCALL
00649 GDALCreateRasterAttributeTable(void);
00650 void CPL_DLL CPL_STDCALL GDALDestroyRasterAttributeTable(
00651 GDALRasterAttributeTableH );
00652
00653 int CPL_DLL CPL_STDCALL GDALRATGetColumnCount( GDALRasterAttributeTableH );
00654
00655 const char CPL_DLL * CPL_STDCALL GDALRATGetNameOfCol(
00656 GDALRasterAttributeTableH, int );
00657 GDALRATFieldUsage CPL_DLL CPL_STDCALL GDALRATGetUsageOfCol(
00658 GDALRasterAttributeTableH, int );
00659 GDALRATFieldType CPL_DLL CPL_STDCALL GDALRATGetTypeOfCol(
00660 GDALRasterAttributeTableH, int );
00661
00662 int CPL_DLL CPL_STDCALL GDALRATGetColOfUsage( GDALRasterAttributeTableH,
00663 GDALRATFieldUsage );
00664 int CPL_DLL CPL_STDCALL GDALRATGetRowCount( GDALRasterAttributeTableH );
00665
00666 const char CPL_DLL * CPL_STDCALL GDALRATGetValueAsString(
00667 GDALRasterAttributeTableH, int ,int);
00668 int CPL_DLL CPL_STDCALL GDALRATGetValueAsInt(
00669 GDALRasterAttributeTableH, int ,int);
00670 double CPL_DLL CPL_STDCALL GDALRATGetValueAsDouble(
00671 GDALRasterAttributeTableH, int ,int);
00672
00673 void CPL_DLL CPL_STDCALL GDALRATSetValueAsString( GDALRasterAttributeTableH, int, int,
00674 const char * );
00675 void CPL_DLL CPL_STDCALL GDALRATSetValueAsInt( GDALRasterAttributeTableH, int, int,
00676 int );
00677 void CPL_DLL CPL_STDCALL GDALRATSetValueAsDouble( GDALRasterAttributeTableH, int, int,
00678 double );
00679 void CPL_DLL CPL_STDCALL GDALRATSetRowCount( GDALRasterAttributeTableH,
00680 int );
00681 CPLErr CPL_DLL CPL_STDCALL GDALRATCreateColumn( GDALRasterAttributeTableH,
00682 const char *,
00683 GDALRATFieldType,
00684 GDALRATFieldUsage );
00685 CPLErr CPL_DLL CPL_STDCALL GDALRATSetLinearBinning( GDALRasterAttributeTableH,
00686 double, double );
00687 int CPL_DLL CPL_STDCALL GDALRATGetLinearBinning( GDALRasterAttributeTableH,
00688 double *, double * );
00689 CPLErr CPL_DLL CPL_STDCALL GDALRATInitializeFromColorTable(
00690 GDALRasterAttributeTableH, GDALColorTableH );
00691 void CPL_DLL CPL_STDCALL GDALRATDumpReadable( GDALRasterAttributeTableH,
00692 FILE * );
00693 GDALRasterAttributeTableH CPL_DLL CPL_STDCALL
00694 GDALRATClone( GDALRasterAttributeTableH );
00695
00696 int CPL_DLL CPL_STDCALL GDALRATGetRowOfValue( GDALRasterAttributeTableH , double );
00697
00698
00699
00700
00701
00702
00703 void CPL_DLL CPL_STDCALL GDALSetCacheMax( int nBytes );
00704 int CPL_DLL CPL_STDCALL GDALGetCacheMax(void);
00705 int CPL_DLL CPL_STDCALL GDALGetCacheUsed(void);
00706 int CPL_DLL CPL_STDCALL GDALFlushCacheBlock(void);
00707
00708 CPL_C_END
00709
00710 #endif