Skip to content

Commit

Permalink
Python bindings: add a combineBands option to gdal.Footprint()
Browse files Browse the repository at this point in the history
  • Loading branch information
rouault committed Nov 27, 2023
1 parent 6fd91c8 commit c95f6e7
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions swig/include/python/gdal_python.i
Original file line number Diff line number Diff line change
Expand Up @@ -3406,6 +3406,7 @@ def Rasterize(destNameOrDestDS, srcDS, **kwargs):
def FootprintOptions(options=None,
format=None,
bands=None,
combineBands=None,
srcNodata=None,
ovr=None,
targetCoordinateSystem=None,
Expand All @@ -3429,6 +3430,8 @@ def FootprintOptions(options=None,
output format ("GeoJSON", etc...)
bands:
list of output bands to burn values into
combineBands:
how to combine bands: "union" (default) or "intersection"
srcNodata:
source nodata value(s).
ovr:
Expand Down Expand Up @@ -3476,6 +3479,8 @@ def FootprintOptions(options=None,
if bands is not None:
for b in bands:
new_options += ['-b', str(b)]
if combineBands:
new_options += ["-combine_bands", combineBands]
if targetCoordinateSystem:
new_options += ["-t_cs", targetCoordinateSystem]
if dstSRS:
Expand Down

0 comments on commit c95f6e7

Please sign in to comment.