Open aiqibaobei opened 1 month ago
I would propose to ask this at the main https://github.com/maplibre/maplibre-native repository as I am not familiar with that functionality specifically.
MapLibre Native supports image sources, maybe that is an option for you.
Right now there is no special support for GeoTIFF as far as I am aware.
Yes, I have tried to add some small GeoTIFFs using the following code: sources: { "image": { "type": "image", "url": "https://maplibre.org/maplibre-gl-js/docs/assets/radar.gif", "coordinates": [ [-80.425, 46.437], [-71.516, 46.437], [-71.516, 37.936], [-80.425, 37.936] ] } } However, I found that when the TIFF becomes large, loading becomes very sluggish. Perhaps the underlying code is converting it to PNG format. My goal is to use GDAL to dynamically load the original images within a certain range when the map moves or zooms, and to use thumbnails when the camera height is higher, similar to QGIS. It seems that I should customize a source and layer. Do you have any ideas or suggestions? Will your team add similar functionality in the future? It seems that the native library has the potential to load GeoTIFFs.
@aiqibaobei As far as I understand, loading images is supported, but MapLibre was never designed to handle large images efficiently. However, there is a clean solution for your problem: use MBTiles instead. MBTiles are designed to contain pre-computes graphic assetts for various zoom levels and will be rendered with blazing speed, even on low-end or handheld devices.
@aiqibaobei As far as I understand, loading images is supported, but MapLibre was never designed to handle large images efficiently. However, there is a clean solution for your problem: use MBTiles instead. MBTiles are designed to contain pre-computes graphic assetts for various zoom levels and will be rendered with blazing speed, even on low-end or handheld devices.
Thank you for the suggestion!
Dear MapLibre Development Team,
I hope this message finds you well. I am exploring the capabilities of the MapLibre library and would like to know if it supports loading large GeoTIFF files directly. If this functionality is not natively supported, could you provide guidance on how to implement this using GDAL or other libraries to handle large GeoTIFF files effectively within a MapLibre environment?
Thank you for your assistance!