GDAL
gdal_utils.h
Go to the documentation of this file.
1 /******************************************************************************
2  * $Id: gdal_utils.h dc3819d387764593c0fb5a5c4d02c21a848a4c9d 2018-04-12 18:07:28 +0200 Even Rouault $
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 );
94 void CPL_DLL GDALWarpAppOptionsSetQuiet( GDALWarpAppOptions *psOptions,
95  int bQuiet );
97  const char* pszKey,
98  const char* pszValue );
99 
100 GDALDatasetH CPL_DLL GDALWarp( const char *pszDest, GDALDatasetH hDstDS,
101  int nSrcCount, GDALDatasetH *pahSrcDS,
102  const GDALWarpAppOptions *psOptions, int *pbUsageError );
103 
106 
109 
111  GDALVectorTranslateOptionsForBinary* psOptionsForBinary);
112 
114 
116  GDALProgressFunc pfnProgress,
117  void *pProgressData );
118 
119 GDALDatasetH CPL_DLL GDALVectorTranslate( const char *pszDest, GDALDatasetH hDstDS, int nSrcCount,
120  GDALDatasetH *pahSrcDS,
121  const GDALVectorTranslateOptions *psOptions, int *pbUsageError );
122 
125 
128 
129 GDALDEMProcessingOptions CPL_DLL *GDALDEMProcessingOptionsNew(char** papszArgv,
130  GDALDEMProcessingOptionsForBinary* psOptionsForBinary);
131 
132 void CPL_DLL GDALDEMProcessingOptionsFree( GDALDEMProcessingOptions *psOptions );
133 
135  GDALProgressFunc pfnProgress,
136  void *pProgressData );
137 
138 GDALDatasetH CPL_DLL GDALDEMProcessing(const char *pszDestFilename,
139  GDALDatasetH hSrcDataset,
140  const char* pszProcessing,
141  const char* pszColorFilename,
142  const GDALDEMProcessingOptions *psOptions,
143  int *pbUsageError);
144 
147 
150 
151 GDALNearblackOptions CPL_DLL *GDALNearblackOptionsNew(char** papszArgv,
152  GDALNearblackOptionsForBinary* psOptionsForBinary);
153 
154 void CPL_DLL GDALNearblackOptionsFree( GDALNearblackOptions *psOptions );
155 
157  GDALProgressFunc pfnProgress,
158  void *pProgressData );
159 
160 GDALDatasetH CPL_DLL GDALNearblack( const char *pszDest, GDALDatasetH hDstDS,
161  GDALDatasetH hSrcDS,
162  const GDALNearblackOptions *psOptions, int *pbUsageError );
163 
166 
169 
170 GDALGridOptions CPL_DLL *GDALGridOptionsNew(char** papszArgv,
171  GDALGridOptionsForBinary* psOptionsForBinary);
172 
173 void CPL_DLL GDALGridOptionsFree( GDALGridOptions *psOptions );
174 
175 void CPL_DLL GDALGridOptionsSetProgress( GDALGridOptions *psOptions,
176  GDALProgressFunc pfnProgress,
177  void *pProgressData );
178 
179 GDALDatasetH CPL_DLL GDALGrid( const char *pszDest,
180  GDALDatasetH hSrcDS,
181  const GDALGridOptions *psOptions, int *pbUsageError );
182 
185 
188 
189 GDALRasterizeOptions CPL_DLL *GDALRasterizeOptionsNew(char** papszArgv,
190  GDALRasterizeOptionsForBinary* psOptionsForBinary);
191 
192 void CPL_DLL GDALRasterizeOptionsFree( GDALRasterizeOptions *psOptions );
193 
195  GDALProgressFunc pfnProgress,
196  void *pProgressData );
197 
198 GDALDatasetH CPL_DLL GDALRasterize( const char *pszDest, GDALDatasetH hDstDS,
199  GDALDatasetH hSrcDS,
200  const GDALRasterizeOptions *psOptions, int *pbUsageError );
201 
204 
207 
208 GDALBuildVRTOptions CPL_DLL *GDALBuildVRTOptionsNew(char** papszArgv,
209  GDALBuildVRTOptionsForBinary* psOptionsForBinary);
210 
211 void CPL_DLL GDALBuildVRTOptionsFree( GDALBuildVRTOptions *psOptions );
212 
213 void CPL_DLL GDALBuildVRTOptionsSetProgress( GDALBuildVRTOptions *psOptions,
214  GDALProgressFunc pfnProgress,
215  void *pProgressData );
216 
217 GDALDatasetH CPL_DLL GDALBuildVRT( const char *pszDest,
218  int nSrcCount, GDALDatasetH *pahSrcDS, const char* const* papszSrcDSNames,
219  const GDALBuildVRTOptions *psOptions, int *pbUsageError );
220 
221 CPL_C_END
222 
223 #endif /* GDAL_UTILS_H_INCLUDED */
void GDALVectorTranslateOptionsFree(GDALVectorTranslateOptions *psOptions)
Frees the GDALVectorTranslateOptions struct.
Definition: ogr2ogr_lib.cpp:5574
void GDALVectorTranslateOptionsSetProgress(GDALVectorTranslateOptions *psOptions, GDALProgressFunc pfnProgress, void *pProgressData)
Set a progress function.
Definition: ogr2ogr_lib.cpp:5637
GDALTranslateOptions * GDALTranslateOptionsNew(char **papszArgv, GDALTranslateOptionsForBinary *psOptionsForBinary)
Allocates a GDALTranslateOptions struct.
Definition: gdal_translate_lib.cpp:2062
struct GDALBuildVRTOptionsForBinary GDALBuildVRTOptionsForBinary
Opaque type.
Definition: gdal_utils.h:206
Core portability definitions for CPL.
#define CPL_C_START
Macro to start a block of C symbols.
Definition: cpl_port.h:337
struct GDALRasterizeOptionsForBinary GDALRasterizeOptionsForBinary
Opaque type.
Definition: gdal_utils.h:187
void GDALDEMProcessingOptionsSetProgress(GDALDEMProcessingOptions *psOptions, GDALProgressFunc pfnProgress, void *pProgressData)
Set a progress function.
Definition: gdaldem_lib.cpp:4059
GDALGridOptions * GDALGridOptionsNew(char **papszArgv, GDALGridOptionsForBinary *psOptionsForBinary)
Allocates a GDALGridOptions struct.
Definition: gdal_grid_lib.cpp:993
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:828
void * GDALDatasetH
Opaque type used for the C bindings of the C++ GDALDataset class.
Definition: gdal.h:255
void GDALTranslateOptionsSetProgress(GDALTranslateOptions *psOptions, GDALProgressFunc pfnProgress, void *pProgressData)
Set a progress function.
Definition: gdal_translate_lib.cpp:2709
struct GDALWarpAppOptionsForBinary GDALWarpAppOptionsForBinary
Opaque type.
Definition: gdal_utils.h:84
GDALBuildVRTOptions * GDALBuildVRTOptionsNew(char **papszArgv, GDALBuildVRTOptionsForBinary *psOptionsForBinary)
Allocates a GDALBuildVRTOptions struct.
Definition: gdalbuildvrt_lib.cpp:1681
struct GDALVectorTranslateOptions GDALVectorTranslateOptions
Definition: gdal_utils.h:105
GDALInfoOptions * GDALInfoOptionsNew(char **papszArgv, GDALInfoOptionsForBinary *psOptionsForBinary)
Allocates a GDALInfoOptions struct.
Definition: gdalinfo_lib.cpp:1803
struct GDALNearblackOptionsForBinary GDALNearblackOptionsForBinary
Opaque type.
Definition: gdal_utils.h:149
GDALDEMProcessingOptions * GDALDEMProcessingOptionsNew(char **papszArgv, GDALDEMProcessingOptionsForBinary *psOptionsForBinary)
Allocates a GDALDEMProcessingOptions struct.
Definition: gdaldem_lib.cpp:3776
struct GDALGridOptions GDALGridOptions
Definition: gdal_utils.h:165
GDALVectorTranslateOptions * GDALVectorTranslateOptionsNew(char **papszArgv, GDALVectorTranslateOptionsForBinary *psOptionsForBinary)
allocates a GDALVectorTranslateOptions struct.
Definition: ogr2ogr_lib.cpp:4863
void GDALWarpAppOptionsSetProgress(GDALWarpAppOptions *psOptions, GDALProgressFunc pfnProgress, void *pProgressData)
Set a progress function.
Definition: gdalwarp_lib.cpp:3785
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:1540
void GDALGridOptionsFree(GDALGridOptions *psOptions)
Frees the GDALGridOptions struct.
Definition: gdal_grid_lib.cpp:1363
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:1228
void GDALWarpAppOptionsSetWarpOption(GDALWarpAppOptions *psOptions, const char *pszKey, const char *pszValue)
Set a warp option.
Definition: gdalwarp_lib.cpp:3827
Public (C callable) GDAL entry points.
struct GDALGridOptionsForBinary GDALGridOptionsForBinary
Opaque type.
Definition: gdal_utils.h:168
struct GDALDEMProcessingOptionsForBinary GDALDEMProcessingOptionsForBinary
Opaque type.
Definition: gdal_utils.h:127
void GDALDEMProcessingOptionsFree(GDALDEMProcessingOptions *psOptions)
Frees the GDALDEMProcessingOptions struct.
Definition: gdaldem_lib.cpp:4034
struct GDALInfoOptionsForBinary GDALInfoOptionsForBinary
Opaque type.
Definition: gdal_utils.h:52
struct GDALVectorTranslateOptionsForBinary GDALVectorTranslateOptionsForBinary
Opaque type.
Definition: gdal_utils.h:108
char * GDALInfo(GDALDatasetH hDataset, const GDALInfoOptions *psOptions)
Lists various information about a GDAL supported raster dataset.
Definition: gdalinfo_lib.cpp:206
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:1907
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:3256
GDALDatasetH GDALGrid(const char *pszDest, GDALDatasetH hSrcDS, const GDALGridOptions *psOptions, int *pbUsageError)
Create raster from the scattered data.
Definition: gdal_grid_lib.cpp:726
struct GDALRasterizeOptions GDALRasterizeOptions
Definition: gdal_utils.h:184
void GDALWarpAppOptionsFree(GDALWarpAppOptions *psOptions)
Frees the GDALWarpAppOptions struct.
Definition: gdalwarp_lib.cpp:3750
struct GDALBuildVRTOptions GDALBuildVRTOptions
Definition: gdal_utils.h:203
struct GDALNearblackOptions GDALNearblackOptions
Definition: gdal_utils.h:146
void GDALTranslateOptionsFree(GDALTranslateOptions *psOptions)
Frees the GDALTranslateOptions struct.
Definition: gdal_translate_lib.cpp:2674
struct GDALWarpAppOptions GDALWarpAppOptions
Definition: gdal_utils.h:81
void GDALWarpAppOptionsSetQuiet(GDALWarpAppOptions *psOptions, int bQuiet)
Set a progress function.
Definition: gdalwarp_lib.cpp:3807
GDALWarpAppOptions * GDALWarpAppOptionsNew(char **papszArgv, GDALWarpAppOptionsForBinary *psOptionsForBinary)
Allocates a GDALWarpAppOptions struct.
Definition: gdalwarp_lib.cpp:3280
void GDALGridOptionsSetProgress(GDALGridOptions *psOptions, GDALProgressFunc pfnProgress, void *pProgressData)
Set a progress function.
Definition: gdal_grid_lib.cpp:1399
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:767
void GDALNearblackOptionsFree(GDALNearblackOptions *psOptions)
Frees the GDALNearblackOptions struct.
Definition: nearblack_lib.cpp:918
void GDALRasterizeOptionsSetProgress(GDALRasterizeOptions *psOptions, GDALProgressFunc pfnProgress, void *pProgressData)
Set a progress function.
Definition: gdal_rasterize_lib.cpp:1261
void GDALInfoOptionsFree(GDALInfoOptions *psOptions)
Frees the GDALInfoOptions struct.
Definition: gdalinfo_lib.cpp:1927
#define CPL_C_END
Macro to end a block of C symbols.
Definition: cpl_port.h:339
void GDALNearblackOptionsSetProgress(GDALNearblackOptions *psOptions, GDALProgressFunc pfnProgress, void *pProgressData)
Set a progress function.
Definition: nearblack_lib.cpp:942
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:583
void GDALBuildVRTOptionsSetProgress(GDALBuildVRTOptions *psOptions, GDALProgressFunc pfnProgress, void *pProgressData)
Set a progress function.
Definition: gdalbuildvrt_lib.cpp:1941
void GDALBuildVRTOptionsFree(GDALBuildVRTOptions *psOptions)
Frees the GDALBuildVRTOptions struct.
Definition: gdalbuildvrt_lib.cpp:1911
GDALDatasetH GDALTranslate(const char *pszDestFilename, GDALDatasetH hSrcDataset, const GDALTranslateOptions *psOptions, int *pbUsageError)
Converts raster data between different formats.
Definition: gdal_translate_lib.cpp:527
GDALNearblackOptions * GDALNearblackOptionsNew(char **papszArgv, GDALNearblackOptionsForBinary *psOptionsForBinary)
Allocates a GDALNearblackOptions struct.
Definition: nearblack_lib.cpp:763
struct GDALDEMProcessingOptions GDALDEMProcessingOptions
Definition: gdal_utils.h:124
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:108

Generated for GDAL by doxygen 1.8.13.