Chris,

I don't see a way in the C API to obtain the pipeline algorithm step
registry or access the step algorithms to obtain their argument
properties and values. Would GetStepAlg()  and related methods
potentially be exposed in the C API at some point, along with a
"GetStepRegistry"?
That could be an option. Another already existing one is to use GDALAlgorithmGetUsageAsJSON() on the pipeline algorithm. You'll get the step algorithms and their arguments under the "pipeline_algorithms" key. Please file a ticket if you prefer the C API.

When run as described above, the main pipeline (actual) algorithm
object has an output arg of type DATASET, but it is not explicitly set
and has null value even though the file output is successfully
generated. I assume the dataset object is available in the output arg
of the "write" step algorithm, but I haven't followed that code
closely enough to understand some details. If that is correct though,
could the final output dataset be propagated up to the main pipeline
algorithm "output" arg?
I suspect a mis-use of the API, because that definitely works as shown by the following Python snippet (which uses the C API)

>>> from osgeo import gdal
>>> alg = gdal.Run('raster pipeline', pipeline='read autotest/gcore/data/byte.tif ! write /vsimem/out.tif')
>>> print(alg.Output().GetDescription())
/vsimem/out.tif

Maybe you run GDALAlgorithmFinalize() ? If so then the output dataset gets closed and the output dataset arg is nullified.

Even

--
http://www.spatialys.com
My software is free, but my time generally not.
_______________________________________________
gdal-dev mailing list
gdal-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/gdal-dev

Reply via email to