Skip to content

Commit 85d34c5

Browse files
authored
Merge pull request #1835 from kikislater/patch-6
Fix #1834 Update generate_png function
2 parents b2668ca + 5e685d6 commit 85d34c5

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

opendm/orthophoto.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,9 +58,9 @@ def generate_png(orthophoto_file, output_file=None, outsize=None):
5858
green = bands.get(gdal.GCI_GreenBand)
5959
blue = bands.get(gdal.GCI_BlueBand)
6060
if red is None or green is None or blue is None:
61-
params.append("-b %s -b %s -b %s" % (red, green, blue))
62-
else:
6361
params.append("-b 1 -b 2 -b 3")
62+
else:
63+
params.append("-b %s -b %s -b %s" % (red, green, blue))
6464
elif gtif.RasterCount <= 2:
6565
params.append("-b 1")
6666

0 commit comments

Comments
 (0)