forked from OSGeo/gdal
-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathgdalalg_raster_index.h
68 lines (54 loc) · 2.16 KB
/
gdalalg_raster_index.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
/******************************************************************************
*
* Project: GDAL
* Purpose: gdal "raster index" subcommand
* Author: Even Rouault <even dot rouault at spatialys.com>
*
******************************************************************************
* Copyright (c) 2025, Even Rouault <even dot rouault at spatialys.com>
*
* SPDX-License-Identifier: MIT
****************************************************************************/
#ifndef GDALALG_RASTER_INDEX_INCLUDED
#define GDALALG_RASTER_INDEX_INCLUDED
#include "gdalalg_vector_output_abstract.h"
//! @cond Doxygen_Suppress
/************************************************************************/
/* GDALRasterIndexAlgorithm */
/************************************************************************/
class CPL_DLL GDALRasterIndexAlgorithm /* non final */
: public GDALVectorOutputAbstractAlgorithm
{
public:
static constexpr const char *NAME = "index";
static constexpr const char *DESCRIPTION =
"Create a vector index of raster datasets.";
static constexpr const char *HELP_URL = "/programs/gdal_raster_index.html";
GDALRasterIndexAlgorithm();
GDALRasterIndexAlgorithm(const std::string &name,
const std::string &description,
const std::string &helpURL);
protected:
void AddCommonOptions();
// Virtual method that may be overridden by derived classes to add options
// to GDALTileIndex()
virtual bool AddExtraOptions([[maybe_unused]] CPLStringList &aosOptions)
{
return true;
}
std::vector<GDALArgDatasetValue> m_inputDatasets{};
private:
bool RunImpl(GDALProgressFunc pfnProgress, void *pProgressData) override;
bool m_recursive = false;
std::vector<std::string> m_filenameFilter{};
double m_minPixelSize = 0;
double m_maxPixelSize = 0;
std::string m_locationName = "location";
bool m_writeAbsolutePaths = false;
std::string m_crs{};
std::string m_sourceCrsName{};
std::string m_sourceCrsFormat = "auto";
std::vector<std::string> m_metadata{};
};
//! @endcond
#endif