13#ifndef GDALALG_RASTER_SLOPE_INCLUDED
14#define GDALALG_RASTER_SLOPE_INCLUDED
16#include "gdalalg_raster_pipeline.h"
26class GDALRasterSlopeAlgorithm
27 :
public GDALRasterPipelineStepAlgorithm
30 static constexpr const char *NAME =
"slope";
31 static constexpr const char *DESCRIPTION =
"Generate a slope map";
32 static constexpr const char *HELP_URL =
"/programs/gdal_raster_slope.html";
34 explicit GDALRasterSlopeAlgorithm(
bool standaloneStep =
false);
37 bool RunStep(GDALPipelineStepRunContext &ctxt)
override;
40 std::string m_unit =
"degree";
41 double m_xscale = std::numeric_limits<double>::quiet_NaN();
42 double m_yscale = std::numeric_limits<double>::quiet_NaN();
43 std::string m_gradientAlg =
"Horn";
44 bool m_noEdges =
false;
51class GDALRasterSlopeAlgorithmStandalone final :
public GDALRasterSlopeAlgorithm
54 GDALRasterSlopeAlgorithmStandalone()
55 : GDALRasterSlopeAlgorithm( true)
59 ~GDALRasterSlopeAlgorithmStandalone()
override;