Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: handle standardising paletted tiffs #547

Merged
merged 4 commits into from
Jul 12, 2023

Conversation

ajacombs
Copy link
Contributor

These changes handle TIFFs with a band of Palette colour interpretation type, using the -expand argument to gdal_translate. This takes the contents of the colour palette and applies it to the rgb/rgba bands in the output file.

This resolves the following error encountered when standardising historical imagery survey SN9911:

ERROR 6: GTIFFBuildOverviews() doesn't support building overviews of multiple colormapped bands.

which used the band arguements -b 1 -b 1 -b 1.

This PR supersedes #310 which was proposed when previously processing historical imagery. I've made a new PR mainly to simplify having to rebase 6 months worth of changes from master onto that branch.

Changes from the earlier PR are that I have now removed the raising of an exception and the handling to catch it, which were the aspects still under discussion preventing it being merged.

@ajacombs ajacombs requested a review from a team as a code owner July 12, 2023 00:04
@ajacombs ajacombs force-pushed the feat/standardise-paletted-tiffs branch from 4843029 to 4b32252 Compare July 12, 2023 00:11
@ajacombs ajacombs force-pushed the feat/standardise-paletted-tiffs branch from 7ff6777 to ccd758c Compare July 12, 2023 03:58
Copy link
Collaborator

@paulfouquet paulfouquet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just some comments needed for understanding.
Otherwise looks good

scripts/gdal/gdalinfo.py Show resolved Hide resolved
paulfouquet
paulfouquet previously approved these changes Jul 12, 2023
@ajacombs ajacombs added this pull request to the merge queue Jul 12, 2023
Merged via the queue into master with commit aa6ce05 Jul 12, 2023
@ajacombs ajacombs deleted the feat/standardise-paletted-tiffs branch July 12, 2023 22:29
@github-actions github-actions bot mentioned this pull request Jul 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants