GDAL

gdalalg_raster_mosaic_stack_common.h
1/******************************************************************************
2 *
3 * Project: GDAL
4 * Purpose: Common code of "raster mosaic" and "raster stack"
5 * Author: Even Rouault <even dot rouault at spatialys.com>
6 *
7 ******************************************************************************
8 * Copyright (c) 2025, Even Rouault <even dot rouault at spatialys.com>
9 *
10 * SPDX-License-Identifier: MIT
11 ****************************************************************************/
12
13#ifndef GDALALG_RASTER_MOSAIC_STACK_COMMON_INCLUDED
14#define GDALALG_RASTER_MOSAIC_STACK_COMMON_INCLUDED
15
16#include "gdalalg_raster_pipeline.h"
17#include "cpl_string.h"
18
20
21/************************************************************************/
22/* GDALRasterMosaicStackCommonAlgorithm */
23/************************************************************************/
24
25 class GDALRasterMosaicStackCommonAlgorithm /* non final */
26 : public GDALRasterPipelineStepAlgorithm
27{
28 public:
29 GDALRasterMosaicStackCommonAlgorithm(const std::string &name,
30 const std::string &description,
31 const std::string &helpURL,
32 bool bStandalone);
33
34 static ConstructorOptions GetConstructorOptions(bool standaloneStep);
35
36 protected:
37 bool RunImpl(GDALProgressFunc pfnProgress, void *pProgressData) override;
38
39 bool GetInputDatasetNames(GDALPipelineStepRunContext &ctxt,
40 std::vector<GDALDatasetH> &ahInputDatasets,
41 CPLStringList &aosInputDatasetNames,
42 bool &foundByName);
43
44 void SetBuildVRTOptions(CPLStringList &aosOptions);
45
46 std::string m_resolution{};
47 std::vector<double> m_bbox{};
48 bool m_targetAlignedPixels = false;
49 std::vector<double> m_srcNoData{};
50 std::vector<double> m_dstNoData{};
51 std::vector<int> m_bands{};
52 bool m_hideNoData = false;
53 bool m_writeAbsolutePaths = false;
54};
55
57
58#endif
CPLStringList
String list class designed around our use of C "char**" string lists.
Definition cpl_string.h:454
cpl_string.h
Various convenience functions for working with strings and string lists.