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

Fix alpha on some GDAL sources #909

Merged
merged 1 commit into from
Aug 4, 2022
Merged

Fix alpha on some GDAL sources #909

merged 1 commit into from
Aug 4, 2022

Conversation

manthey
Copy link
Member

@manthey manthey commented Aug 4, 2022

This affected sources with a projection that have an explicit alpha channel.

Fixes girder/django-large-image#39

This affected sources with a projection that have an explicit alpha
channel.
@manthey manthey merged commit f7c6c47 into master Aug 4, 2022
@manthey manthey deleted the fix-projection-alpha branch August 4, 2022 18:29
@banesullivan
Copy link
Contributor

Turns out this didn't completely fix the issue:

In the following example, the alpha is still improperly handled

import large_image

path = '/Users/bane/Desktop/rasters/Django-Large-Image/4-ortho-rgb-cog.tif'

src = large_image.open(path, projection='EPSG:3857', style={
 'bands': [
    {'band': 1, 'palette': 'R'},
    {'band': 2, 'palette': 'G'},
    {'band': 3, 'palette': 'B'}
  ]
})
thumb = src.getThumbnail(encoding='PNG')[0]
thumb

download

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

EPSG and its effect on COG and Tiles Opacity
2 participants