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

renderPng(colorMap) treats Int rasters as Double #2022

Closed
echeipesh opened this Issue Feb 17, 2017 · 2 comments

Comments

Projects
None yet
2 participants
@echeipesh
Contributor

echeipesh commented Feb 17, 2017

def renderPng(colorRamp: ColorRamp): Png = {
if(self.cellType.isFloatingPoint) {
val histogram = self.histogram
val quantileBreaks = histogram.quantileBreaks(colorRamp.numStops)
renderPng(new IntColorMap(quantileBreaks.zip(colorRamp.colors).toMap).cache(histogram))
} else {
val histogram = self.histogramDouble
renderPng(ColorMap.fromQuantileBreaks(histogram, colorRamp))
}
}

@echeipesh

This comment has been minimized.

Contributor

echeipesh commented Feb 17, 2017

pomadchin added a commit to pomadchin/geotrellis that referenced this issue Feb 22, 2017

fixes locationtech#2022
Signed-off-by: Grigory Pomadchin <gr.pomadchin@gmail.com>

@pomadchin pomadchin self-assigned this Feb 22, 2017

@pomadchin

This comment has been minimized.

Member

pomadchin commented Feb 22, 2017

Rob already mentioned this bug #1957

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment