We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
@khannurien , how many bands does your raster have?
If it's a simple 3-Band RGB raster you could do:
pixelValuesToColorFn: values => values[0] === -99.0 ? null : `rgb(${values[0]},${values[1]},${values[2]})`
If it's a four-band RGBA raster, you could do:
pixelValuesToColorFn: values => values[0] === -99.0 ? null : `rgba(${values[0]},${values[1]},${values[2]},${values[3]/255})`
If it's not 3 or 4-bands, things get more complicated, but I'm happy to help.
Please let me know if it works or if you have any other questions. I'd like to improve the documentation to make it more clear. Thanks!!
Originally posted by @DanielJDufour in #16 (comment)
As you mentioned above it is complicated to handle rasters with more than 4 bands. But how can i do that? My raster has 10 bands.
The text was updated successfully, but these errors were encountered:
Do you mean converting a 10 band pixel to a 3 band (RGB) pixel, or something like calculating e.g. an NDVI out of some of the bands?
Sorry, something went wrong.
No branches or pull requests
If it's a simple 3-Band RGB raster you could do:
If it's a four-band RGBA raster, you could do:
If it's not 3 or 4-bands, things get more complicated, but I'm happy to help.
Please let me know if it works or if you have any other questions. I'd like to improve the documentation to make it more clear. Thanks!!
Originally posted by @DanielJDufour in #16 (comment)
As you mentioned above it is complicated to handle rasters with more than 4 bands. But how can i do that? My raster has 10 bands.
The text was updated successfully, but these errors were encountered: