13#ifndef GDALALG_RASTER_PIXEL_INFO_INCLUDED
14#define GDALALG_RASTER_PIXEL_INFO_INCLUDED
16#include "gdalalg_abstract_pipeline.h"
18#include "cpl_vsi_virtual.h"
26class GDALRasterPixelInfoAlgorithm
27 :
public GDALPipelineStepAlgorithm
30 static constexpr const char *NAME =
"pixel-info";
31 static constexpr const char *DESCRIPTION =
32 "Return information on a pixel of a raster dataset.";
33 static constexpr const char *HELP_URL =
34 "/programs/gdal_raster_pixel_info.html";
36 explicit GDALRasterPixelInfoAlgorithm(
bool standaloneStep =
false);
37 ~GDALRasterPixelInfoAlgorithm()
override;
39 bool IsNativelyStreamingCompatible()
const override
47 int GetInputType()
const override
52 int GetOutputType()
const override
58 bool RunStep(GDALPipelineStepRunContext &ctxt)
override;
59 bool RunImpl(GDALProgressFunc pfnProgress,
void *pProgressData)
override;
62 std::vector<std::string> m_includeFields{
"ALL"};
64 std::vector<int> m_band{};
66 std::vector<double> m_pos{};
67 std::string m_posCrs{};
68 std::string m_resampling =
"nearest";
69 bool m_promotePixelValueToZ =
false;
71 VSIVirtualHandleUniquePtr m_outputFile{};
72 std::string m_osTmpFilename{};
79class GDALRasterPixelInfoAlgorithmStandalone final
80 :
public GDALRasterPixelInfoAlgorithm
83 GDALRasterPixelInfoAlgorithmStandalone()
84 : GDALRasterPixelInfoAlgorithm( true)
88 ~GDALRasterPixelInfoAlgorithmStandalone()
override;
Value for an argument that points to a GDALDataset.
Definition gdalalgorithm_cpp.h:163
#define GDAL_OF_RASTER
Allow raster drivers to be used.
Definition gdal.h:1125
#define GDAL_OF_VECTOR
Allow vector drivers to be used.
Definition gdal.h:1130