Discussion:
[gdal-dev] help with GDALWarpApp - resample options
Michael Sumner
2021-05-14 21:13:03 UTC
Permalink
Hello,

how do I set the equivalent of eResampleAlg for the GDALWarp *app* ?

https://gdal.org/api/gdal_utils.html#gdal__utils_8h_1ab2094d5332364d63e0851dcb12398469

I think you can't? GDALWarpAppOptions is for the -wo command line
equivalents, not the -r (right?)

I can see how to use the implementation of the GDALWarpApp to get what I
want, but if this resample method was settable it saves me going lower.

Thanks!

Best, Mike
--
Michael Sumner
Software and Database Engineer
Australian Antarctic Division
Hobart, Australia
e-mail: ***@gmail.com
Even Rouault
2021-05-14 21:18:33 UTC
Permalink
Michael,
Post by Michael Sumner
how do I set the equivalent of eResampleAlg for the GDALWarp *app* ?
https://gdal.org/api/gdal_utils.html#gdal__utils_8h_1ab2094d5332364d63e0851dcb12398469
<https://gdal.org/api/gdal_utils.html#gdal__utils_8h_1ab2094d5332364d63e0851dcb12398469>
I think you can't?  GDALWarpAppOptions is for the -wo command line
equivalents, not the -r (right?)
GDALWarpAppOptions is for all command line parameters of gdalwarp, not
just -wo

Usage example at
https://github.com/OSGeo/gdal/blob/fec15b146f8a750c23c5e765cac12ed5fc9c2b85/gdal/frmts/gtiff/cogdriver.cpp#L512

Even
--
http://www.spatialys.com
My software is free, but my time generally not.
Michael Sumner
2021-05-14 21:20:43 UTC
Permalink
Oh, I see - you just append it all on.

Thanks! C++ is a real struggle for me, but this is going to be excellent.

Best, Mike
Post by Even Rouault
Michael,
Post by Michael Sumner
how do I set the equivalent of eResampleAlg for the GDALWarp *app* ?
https://gdal.org/api/gdal_utils.html#gdal__utils_8h_1ab2094d5332364d63e0851dcb12398469
Post by Michael Sumner
<
https://gdal.org/api/gdal_utils.html#gdal__utils_8h_1ab2094d5332364d63e0851dcb12398469
Post by Michael Sumner
I think you can't? GDALWarpAppOptions is for the -wo command line
equivalents, not the -r (right?)
GDALWarpAppOptions is for all command line parameters of gdalwarp, not
just -wo
Usage example at
https://github.com/OSGeo/gdal/blob/fec15b146f8a750c23c5e765cac12ed5fc9c2b85/gdal/frmts/gtiff/cogdriver.cpp#L512
Even
--
http://www.spatialys.com
My software is free, but my time generally not.
Loading...