-
Notifications
You must be signed in to change notification settings - Fork 26
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
No color in the GeoTIFF #5
Comments
Hi, @meteozgz . Thanks for posting this issue. I'll look into it. |
Hi, @meteozgz . GeoRasterLayer doesn't currently support color tables, but you can use the pixelValuesToColorFn as a workaround. You can grab the color table is JSON file using gdalinfo. Here's the command:
Here's some sample code:
Let me know if this helps! Happy to answer any more questions. Hopefully, we'll get color table support added into GeoRasterLayer in the future. |
Hello Daniel, I try with your code but doesn't work... This is the code and you can see in http://radarzgz.meteozgz.eu/geotif3.html : ` <style> #map { bottom: 0; left: 0; position: absolute; right: 0; top: 0; } </style> <script src="https://unpkg.com/[email protected]/dist/leaflet.js"></script> <script src="https://unpkg.com/georaster"></script> <script src="https://unpkg.com/georaster-layer-for-leaflet/georaster-layer-for-leaflet.browserify.min.js"></script> <script> // initalize leaflet map var map = L.map('map').setView([41.7, 0], 5);
Probably I don't know how to put the code... Thank you very much and sorry. Carlos C. |
No problem. It seems like this line |
Hi Daniel, I tried but still doesn't work... Have I put the all path of the last2.json? |
My mistake. The A value in rgba should be between 0 and 1, so we must divide by 255. Like |
Still doesn't work... I think I do some more wrong because now I cannot see anything in the web (no map). This is the code:
|
Hi Daniel, I think I don't put right the JSON, so the script cannot know how to do well. Could be this the problem? I don't know how to fix it because it is my first time with JavaScript code. Sorry for my, maybe, stupid questions and thank you very much for all your help. Carlos C. |
how can i apply Geotiff raster image on different map its in australia region need to apply in canada region like this similar raster image i had tried Qgis and other software to convert to .tiff format https://github.com/stuartmatthews/leaflet-geotiff |
Hello everyone,
I tried to develop a Radar Visor from AEMET images but I can't show the color of the radar. This is the code:
<style> #map { bottom: 0; left: 0; position: absolute; right: 0; top: 0; } </style> <script src="https://unpkg.com/[email protected]/dist/leaflet.js"></script> <script src="https://unpkg.com/georaster"></script> <script src="https://unpkg.com/georaster-layer-for-leaflet/georaster-layer-for-leaflet.browserify.min.js"></script> <script> // initalize leaflet map var map = L.map('map').setView([41.7, 0], 5);`
And you can enter to visor: http://radarzgz.meteozgz.eu/geotif.html The original is this: https://ama.aemet.es/o/estaticos/productos/scm/202004122300_r8za.gif
I don't know how to do to show the original colors...
Thank you very much.
Carlos C.
The text was updated successfully, but these errors were encountered: