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
we can use PixelManipulation, and copy this directly from Infragram.org (https://infragram.org/sandbox/):
https://github.com/publiclab/infragram-js/blob/master/public/infragram.js#L88-L114
that method returns a new function which maps an incoming value (0-255) to an outgoing value, and can be run on each pixel.
Colormap functions are based on a nested array:
https://github.com/publiclab/infragram-js/blob/master/public/infragram.js#L212-L214
var c = segmented_colormap([[0, [0, 0, 255], [38, 195, 195]], [0.5, [0, 150, 0], [255, 255, 0]], [0.75, [255, 255, 0], [255, 50, 50]]]); c(0) // => [0, 0, 255]
then we can make lots of different segmented_colormaps! Gradient colormaps too, but later; this is simpler for now.
Also the Fastie colormap:
colormap_fastie = segmented_colormap([[0, [255, 255, 255], [0, 0, 0]], [0.167, [0, 0, 0], [255, 255, 255]], [0.33, [255, 255, 255], [0, 0, 0]], [0.5, [0, 0, 0], [140, 140, 255]], [0.55, [140, 140, 255], [0, 255, 0]], [0.63, [0, 255, 0], [255, 255, 0]], [0.75, [255, 255, 0], [255, 0, 0]], [0.95, [255, 0, 0], [255, 0, 255]]]); ```
The text was updated successfully, but these errors were encountered:
Added in #57!
Sorry, something went wrong.
ccpandhare
No branches or pull requests
we can use PixelManipulation, and copy this directly from Infragram.org (https://infragram.org/sandbox/):
https://github.com/publiclab/infragram-js/blob/master/public/infragram.js#L88-L114
that method returns a new function which maps an incoming value (0-255) to an outgoing value, and can be run on each pixel.
Colormap functions are based on a nested array:
https://github.com/publiclab/infragram-js/blob/master/public/infragram.js#L212-L214
then we can make lots of different segmented_colormaps! Gradient colormaps too, but later; this is simpler for now.
Also the Fastie colormap:
The text was updated successfully, but these errors were encountered: