GDAL
gdal_utils.h
Go to the documentation of this file.
1 /******************************************************************************
2  * $Id: gdal_utils.h 35884 2016-10-24 05:56:50Z goatbar $
3  *
4  * Project: GDAL Utilities
5  * Purpose: GDAL Utilities Public Declarations.
6  * Author: Faza Mahamood, fazamhd at gmail dot com
7  *
8  * ****************************************************************************
9  * Copyright (c) 1998, Frank Warmerdam
10  * Copyright (c) 2007-2015, Even Rouault <even.rouault at spatialys.com>
11  * Copyright (c) 2015, Faza Mahamood
12  *
13  * Permission is hereby granted, free of charge, to any person obtaining a
14  * copy of this software and associated documentation files (the "Software"),
15  * to deal in the Software without restriction, including without limitation
16  * the rights to use, copy, modify, merge, publish, distribute, sublicense,
17  * and/or sell copies of the Software, and to permit persons to whom the
18  * Software is furnished to do so, subject to the following conditions:
19  *
20  * The above copyright notice and this permission notice shall be included
21  * in all copies or substantial portions of the Software.
22  *
23  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
24  * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
25  * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
26  * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
27  * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
28  * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
29  * DEALINGS IN THE SOFTWARE.
30  ****************************************************************************/
31 
32 #ifndef GDAL_UTILS_H_INCLUDED
33 #define GDAL_UTILS_H_INCLUDED
34 
43 #include "cpl_port.h"
44 #include "gdal.h"
45 
47 
50 
53 
54 GDALInfoOptions CPL_DLL *GDALInfoOptionsNew(char** papszArgv, GDALInfoOptionsForBinary* psOptionsForBinary);
55 
56 void CPL_DLL GDALInfoOptionsFree( GDALInfoOptions *psOptions );
57 
58 char CPL_DLL *GDALInfo( GDALDatasetH hDataset, const GDALInfoOptions *psOptions );
59 
62 
65 
66 GDALTranslateOptions CPL_DLL *GDALTranslateOptionsNew(char** papszArgv,
67  GDALTranslateOptionsForBinary* psOptionsForBinary);
68 
69 void CPL_DLL GDALTranslateOptionsFree( GDALTranslateOptions *psOptions );
70 
72  GDALProgressFunc pfnProgress,
73  void *pProgressData );
74 
75 GDALDatasetH CPL_DLL GDALTranslate(const char *pszDestFilename,
76  GDALDatasetH hSrcDataset,
77  const GDALTranslateOptions *psOptions,
78  int *pbUsageError);
79 
82 
85 
86 GDALWarpAppOptions CPL_DLL *GDALWarpAppOptionsNew(char** papszArgv,
87  GDALWarpAppOptionsForBinary* psOptionsForBinary);
88 
89 void CPL_DLL GDALWarpAppOptionsFree( GDALWarpAppOptions *psOptions );
90 
91 void CPL_DLL GDALWarpAppOptionsSetProgress( GDALWarpAppOptions *psOptions,
92  GDALProgressFunc pfnProgress,
93  void *pProgressData );
95  const char* pszKey,
96  const char* pszValue );
97 
98 GDALDatasetH CPL_DLL GDALWarp( const char *pszDest, GDALDatasetH hDstDS,
99  int nSrcCount, GDALDatasetH *pahSrcDS,
100  const GDALWarpAppOptions *psOptions, int *pbUsageError );
101 
104 
107 
109  GDALVectorTranslateOptionsForBinary* psOptionsForBinary);
110 
112 
114  GDALProgressFunc pfnProgress,
115  void *pProgressData );
116 
117 GDALDatasetH CPL_DLL GDALVectorTranslate( const char *pszDest, GDALDatasetH hDstDS, int nSrcCount,
118  GDALDatasetH *pahSrcDS,
119  const GDALVectorTranslateOptions *psOptions, int *pbUsageError );
120 
123 
126 
127 GDALDEMProcessingOptions CPL_DLL *GDALDEMProcessingOptionsNew(char** papszArgv,
128  GDALDEMProcessingOptionsForBinary* psOptionsForBinary);
129 
130 void CPL_DLL GDALDEMProcessingOptionsFree( GDALDEMProcessingOptions *psOptions );
131 
133  GDALProgressFunc pfnProgress,
134  void *pProgressData );
135 
136 GDALDatasetH CPL_DLL GDALDEMProcessing(const char *pszDestFilename,
137  GDALDatasetH hSrcDataset,
138  const char* pszProcessing,
139  const char* pszColorFilename,
140  const GDALDEMProcessingOptions *psOptions,
141  int *pbUsageError);
142 
145 
148 
149 GDALNearblackOptions CPL_DLL *GDALNearblackOptionsNew(char** papszArgv,
150  GDALNearblackOptionsForBinary* psOptionsForBinary);
151 
152 void CPL_DLL GDALNearblackOptionsFree( GDALNearblackOptions *psOptions );
153 
155  GDALProgressFunc pfnProgress,
156  void *pProgressData );
157 
158 GDALDatasetH CPL_DLL GDALNearblack( const char *pszDest, GDALDatasetH hDstDS,
159  GDALDatasetH hSrcDS,
160  const GDALNearblackOptions *psOptions, int *pbUsageError );
161 
164 
167 
168 GDALGridOptions CPL_DLL *GDALGridOptionsNew(char** papszArgv,
169  GDALGridOptionsForBinary* psOptionsForBinary);
170 
171 void CPL_DLL GDALGridOptionsFree( GDALGridOptions *psOptions );
172 
173 void CPL_DLL GDALGridOptionsSetProgress( GDALGridOptions *psOptions,
174  GDALProgressFunc pfnProgress,
175  void *pProgressData );
176 
177 GDALDatasetH CPL_DLL GDALGrid( const char *pszDest,
178  GDALDatasetH hSrcDS,
179  const GDALGridOptions *psOptions, int *pbUsageError );
180 
183 
186 
187 GDALRasterizeOptions CPL_DLL *GDALRasterizeOptionsNew(char** papszArgv,
188  GDALRasterizeOptionsForBinary* psOptionsForBinary);
189 
190 void CPL_DLL GDALRasterizeOptionsFree( GDALRasterizeOptions *psOptions );
191 
193  GDALProgressFunc pfnProgress,
194  void *pProgressData );
195 
196 GDALDatasetH CPL_DLL GDALRasterize( const char *pszDest, GDALDatasetH hDstDS,
197  GDALDatasetH hSrcDS,
198  const GDALRasterizeOptions *psOptions, int *pbUsageError );
199 
202 
205 
206 GDALBuildVRTOptions CPL_DLL *GDALBuildVRTOptionsNew(char** papszArgv,
207  GDALBuildVRTOptionsForBinary* psOptionsForBinary);
208 
209 void CPL_DLL GDALBuildVRTOptionsFree( GDALBuildVRTOptions *psOptions );
210 
211 void CPL_DLL GDALBuildVRTOptionsSetProgress( GDALBuildVRTOptions *psOptions,
212  GDALProgressFunc pfnProgress,
213  void *pProgressData );
214 
215 GDALDatasetH CPL_DLL GDALBuildVRT( const char *pszDest,
216  int nSrcCount, GDALDatasetH *pahSrcDS, const char* const* papszSrcDSNames,
217  const GDALBuildVRTOptions *psOptions, int *pbUsageError );
218 
219 CPL_C_END
220 
221 #endif /* GDAL_UTILS_H_INCLUDED */
void GDALVectorTranslateOptionsFree(GDALVectorTranslateOptions *psOptions)
Frees the GDALVectorTranslateOptions struct.
Definition: ogr2ogr_lib.cpp:5356
void GDALVectorTranslateOptionsSetProgress(GDALVectorTranslateOptions *psOptions, GDALProgressFunc pfnProgress, void *pProgressData)
Set a progress function.
Definition: ogr2ogr_lib.cpp:5419
GDALTranslateOptions * GDALTranslateOptionsNew(char **papszArgv, GDALTranslateOptionsForBinary *psOptionsForBinary)
Allocates a GDALTranslateOptions struct.
Definition: gdal_translate_lib.cpp:1721
struct GDALBuildVRTOptionsForBinary GDALBuildVRTOptionsForBinary
Opaque type.
Definition: gdal_utils.h:204
Core portability definitions for CPL.
#define CPL_C_START
Macro to start a block of C symbols.
Definition: cpl_port.h:352
struct GDALRasterizeOptionsForBinary GDALRasterizeOptionsForBinary
Opaque type.
Definition: gdal_utils.h:185
void GDALDEMProcessingOptionsSetProgress(GDALDEMProcessingOptions *psOptions, GDALProgressFunc pfnProgress, void *pProgressData)
Set a progress function.
Definition: gdaldem_lib.cpp:4034
GDALGridOptions * GDALGridOptionsNew(char **papszArgv, GDALGridOptionsForBinary *psOptionsForBinary)
Allocates a GDALGridOptions struct.
Definition: gdal_grid_lib.cpp:921
struct GDALTranslateOptionsForBinary GDALTranslateOptionsForBinary
Opaque type.
Definition: gdal_utils.h:64
GDALRasterizeOptions * GDALRasterizeOptionsNew(char **papszArgv, GDALRasterizeOptionsForBinary *psOptionsForBinary)
Allocates a GDALRasterizeOptions struct.
Definition: gdal_rasterize_lib.cpp:764
void * GDALDatasetH
Opaque type used for the C bindings of the C++ GDALDataset class.
Definition: gdal.h:241
void GDALTranslateOptionsSetProgress(GDALTranslateOptions *psOptions, GDALProgressFunc pfnProgress, void *pProgressData)
Set a progress function.
Definition: gdal_translate_lib.cpp:2285
struct GDALWarpAppOptionsForBinary GDALWarpAppOptionsForBinary
Opaque type.
Definition: gdal_utils.h:84
GDALBuildVRTOptions * GDALBuildVRTOptionsNew(char **papszArgv, GDALBuildVRTOptionsForBinary *psOptionsForBinary)
Allocates a GDALBuildVRTOptions struct.
Definition: gdalbuildvrt_lib.cpp:1510
struct GDALVectorTranslateOptions GDALVectorTranslateOptions
Definition: gdal_utils.h:103
GDALInfoOptions * GDALInfoOptionsNew(char **papszArgv, GDALInfoOptionsForBinary *psOptionsForBinary)
Allocates a GDALInfoOptions struct.
Definition: gdalinfo_lib.cpp:1805
struct GDALNearblackOptionsForBinary GDALNearblackOptionsForBinary
Opaque type.
Definition: gdal_utils.h:147
GDALDEMProcessingOptions * GDALDEMProcessingOptionsNew(char **papszArgv, GDALDEMProcessingOptionsForBinary *psOptionsForBinary)
Allocates a GDALDEMProcessingOptions struct.
Definition: gdaldem_lib.cpp:3742
struct GDALGridOptions GDALGridOptions
Definition: gdal_utils.h:163
GDALVectorTranslateOptions * GDALVectorTranslateOptionsNew(char **papszArgv, GDALVectorTranslateOptionsForBinary *psOptionsForBinary)
allocates a GDALVectorTranslateOptions struct.
Definition: ogr2ogr_lib.cpp:4652
void GDALWarpAppOptionsSetProgress(GDALWarpAppOptions *psOptions, GDALProgressFunc pfnProgress, void *pProgressData)
Set a progress function.
Definition: gdalwarp_lib.cpp:3177
GDALDatasetH GDALBuildVRT(const char *pszDest, int nSrcCount, GDALDatasetH *pahSrcDS, const char *const *papszSrcDSNames, const GDALBuildVRTOptions *psOptions, int *pbUsageError)
Build a VRT from a list of datasets.
Definition: gdalbuildvrt_lib.cpp:1370
void GDALGridOptionsFree(GDALGridOptions *psOptions)
Frees the GDALGridOptions struct.
Definition: gdal_grid_lib.cpp:1290
struct GDALTranslateOptions GDALTranslateOptions
Definition: gdal_utils.h:61
struct GDALInfoOptions GDALInfoOptions
Definition: gdal_utils.h:49
void GDALRasterizeOptionsFree(GDALRasterizeOptions *psOptions)
Frees the GDALRasterizeOptions struct.
Definition: gdal_rasterize_lib.cpp:1156
void GDALWarpAppOptionsSetWarpOption(GDALWarpAppOptions *psOptions, const char *pszKey, const char *pszValue)
Set a warp option.
Definition: gdalwarp_lib.cpp:3200
Public (C callable) GDAL entry points.
struct GDALGridOptionsForBinary GDALGridOptionsForBinary
Opaque type.
Definition: gdal_utils.h:166
struct GDALDEMProcessingOptionsForBinary GDALDEMProcessingOptionsForBinary
Opaque type.
Definition: gdal_utils.h:125
void GDALDEMProcessingOptionsFree(GDALDEMProcessingOptions *psOptions)
Frees the GDALDEMProcessingOptions struct.
Definition: gdaldem_lib.cpp:4009
struct GDALInfoOptionsForBinary GDALInfoOptionsForBinary
Opaque type.
Definition: gdal_utils.h:52
struct GDALVectorTranslateOptionsForBinary GDALVectorTranslateOptionsForBinary
Opaque type.
Definition: gdal_utils.h:106
char * GDALInfo(GDALDatasetH hDataset, const GDALInfoOptions *psOptions)
Lists various information about a GDAL supported raster dataset.
Definition: gdalinfo_lib.cpp:204
GDALDatasetH GDALVectorTranslate(const char *pszDest, GDALDatasetH hDstDS, int nSrcCount, GDALDatasetH *pahSrcDS, const GDALVectorTranslateOptions *psOptions, int *pbUsageError)
Converts vector data between file formats.
Definition: ogr2ogr_lib.cpp:1876
GDALDatasetH GDALDEMProcessing(const char *pszDestFilename, GDALDatasetH hSrcDataset, const char *pszProcessing, const char *pszColorFilename, const GDALDEMProcessingOptions *psOptions, int *pbUsageError)
Apply a DEM processing.
Definition: gdaldem_lib.cpp:3236
GDALDatasetH GDALGrid(const char *pszDest, GDALDatasetH hSrcDS, const GDALGridOptions *psOptions, int *pbUsageError)
Create raster from the scattered data.
Definition: gdal_grid_lib.cpp:669
struct GDALRasterizeOptions GDALRasterizeOptions
Definition: gdal_utils.h:182
void GDALWarpAppOptionsFree(GDALWarpAppOptions *psOptions)
Frees the GDALWarpAppOptions struct.
Definition: gdalwarp_lib.cpp:3142
struct GDALBuildVRTOptions GDALBuildVRTOptions
Definition: gdal_utils.h:201
struct GDALNearblackOptions GDALNearblackOptions
Definition: gdal_utils.h:144
void GDALTranslateOptionsFree(GDALTranslateOptions *psOptions)
Frees the GDALTranslateOptions struct.
Definition: gdal_translate_lib.cpp:2250
struct GDALWarpAppOptions GDALWarpAppOptions
Definition: gdal_utils.h:81
GDALWarpAppOptions * GDALWarpAppOptionsNew(char **papszArgv, GDALWarpAppOptionsForBinary *psOptionsForBinary)
Allocates a GDALWarpAppOptions struct.
Definition: gdalwarp_lib.cpp:2671
void GDALGridOptionsSetProgress(GDALGridOptions *psOptions, GDALProgressFunc pfnProgress, void *pProgressData)
Set a progress function.
Definition: gdal_grid_lib.cpp:1326
GDALDatasetH GDALWarp(const char *pszDest, GDALDatasetH hDstDS, int nSrcCount, GDALDatasetH *pahSrcDS, const GDALWarpAppOptions *psOptions, int *pbUsageError)
Image reprojection and warping function.
Definition: gdalwarp_lib.cpp:482
void GDALNearblackOptionsFree(GDALNearblackOptions *psOptions)
Frees the GDALNearblackOptions struct.
Definition: nearblack_lib.cpp:903
void GDALRasterizeOptionsSetProgress(GDALRasterizeOptions *psOptions, GDALProgressFunc pfnProgress, void *pProgressData)
Set a progress function.
Definition: gdal_rasterize_lib.cpp:1188
void GDALInfoOptionsFree(GDALInfoOptions *psOptions)
Frees the GDALInfoOptions struct.
Definition: gdalinfo_lib.cpp:1929
#define CPL_C_END
Macro to end a block of C symbols.
Definition: cpl_port.h:354
void GDALNearblackOptionsSetProgress(GDALNearblackOptions *psOptions, GDALProgressFunc pfnProgress, void *pProgressData)
Set a progress function.
Definition: nearblack_lib.cpp:928
GDALDatasetH GDALRasterize(const char *pszDest, GDALDatasetH hDstDS, GDALDatasetH hSrcDS, const GDALRasterizeOptions *psOptions, int *pbUsageError)
Burns vector geometries into a raster.
Definition: gdal_rasterize_lib.cpp:535
void GDALBuildVRTOptionsSetProgress(GDALBuildVRTOptions *psOptions, GDALProgressFunc pfnProgress, void *pProgressData)
Set a progress function.
Definition: gdalbuildvrt_lib.cpp:1762
void GDALBuildVRTOptionsFree(GDALBuildVRTOptions *psOptions)
Frees the GDALBuildVRTOptions struct.
Definition: gdalbuildvrt_lib.cpp:1733
GDALDatasetH GDALTranslate(const char *pszDestFilename, GDALDatasetH hSrcDataset, const GDALTranslateOptions *psOptions, int *pbUsageError)
Converts raster data between different formats.
Definition: gdal_translate_lib.cpp:495
GDALNearblackOptions * GDALNearblackOptionsNew(char **papszArgv, GDALNearblackOptionsForBinary *psOptionsForBinary)
Allocates a GDALNearblackOptions struct.
Definition: nearblack_lib.cpp:748
struct GDALDEMProcessingOptions GDALDEMProcessingOptions
Definition: gdal_utils.h:122
GDALDatasetH GDALNearblack(const char *pszDest, GDALDatasetH hDstDS, GDALDatasetH hSrcDS, const GDALNearblackOptions *psOptions, int *pbUsageError)
Convert nearly black/white borders to exact value.
Definition: nearblack_lib.cpp:106

Generated for GDAL by doxygen 1.8.8.