Re: [gdal-dev] argument default value in the C API to GDALAlgorithmArg

2025-08-07 Thread Even Rouault via gdal-dev
Chris, in the 3.11 branch "help-doc" is the only argument that calls SetHidden(), so you could hard code that for now, or use the workaround of defining the struct GDALAlgorithmArgHS For 3.12, I've exposed GDALAlgorithmArgIsHidden() in https://github.com/OSGeo/gdal/pull/12890, and rationaliz

Re: [gdal-dev] argument default value in the C API to GDALAlgorithmArg

2025-08-07 Thread Chris Toney via gdal-dev
Even, Got it, thanks. I'm thinking of the case analogous to GDALDataset, OGRGeometry and others that have a fromHandle() method. That is occasionally helpful, when we use primarily the C APIs but there is some public C++ method not exposed in C that we want to use (i.e., "public" via gdal_priv.h i

Re: [gdal-dev] argument default value in the C API to GDALAlgorithmArg

2025-08-07 Thread Even Rouault via gdal-dev
Chris, why would you need it to be exposed ? If it is to workaround missing C API entry points, we should add them Regarding struct GDALAlgorithmHS being exposed in gdalalgorithm.h, this is because another GDAL .cpp file needed it, but I think I should create instead a gdalalgorithm_priv.h h

Re: [gdal-dev] argument default value in the C API to GDALAlgorithmArg

2025-08-06 Thread Chris Toney via gdal-dev
Hi Even, > If you need this in 3.11, you can define the following implementation > detail in your code > > struct GDALAlgorithmArgHS Could GDALAlgorithmArgHS be defined in gdalalgorithm.h (as struct GDALAlgorithmHS is)? Chris On Mon, Aug 4, 2025 at 2:42 AM Even Rouault wrote: > > Hi Chris, > >

Re: [gdal-dev] argument default value in the C API to GDALAlgorithmArg

2025-08-04 Thread Chris Toney via gdal-dev
Hi Even, Much appreciated! That workaround solved for 3.11. Chris On Mon, Aug 4, 2025, 2:42 AM Even Rouault wrote: > Hi Chris, > > This was indeed missing in the C API. Queued for 3.12 in > https://github.com/OSGeo/gdal/pull/12853 > > If you need this in 3.11, you can define the following impl

Re: [gdal-dev] argument default value in the C API to GDALAlgorithmArg

2025-08-04 Thread Even Rouault via gdal-dev
Hi Chris, This was indeed missing in the C API. Queued for 3.12 in https://github.com/OSGeo/gdal/pull/12853 If you need this in 3.11, you can define the following implementation detail in your code struct GDALAlgorithmArgHS {     GDALAlgorithmArg *ptr = nullptr;     explicit GDALAlgorithmA