iTowns / itowns

A Three.js-based framework written in Javascript/WebGL for visualizing 3D geospatial data
http://www.itowns-project.org
Other
1.08k stars 293 forks source link

feature: Add Cloud Optimized GeoTIFF (COG) sample #2250

Closed ketourneau closed 6 months ago

ketourneau commented 7 months ago

Description

We need to display Cloud Optimized GeoTIFF (COG) with iTowns. A pull request already exist about COG but it seems to be abandoned. We tried to used PR but we got some trouble with UTIF library to parse COG. We think geotiff is a better library to parse COG.

Motivation and Context

We need to display heavy georeferenced tif file (geotiff) which come from CAD software. We think the best solution is to convert geotiff to COG and display it with iTowns. Maybe it can help this discussion ?

We will change the sample url if this PR on itowns data is accepted (or maybe we don't need to change the sample url ?).

Pourfex commented 7 months ago

We only support COG that are generated throught this command :

gdal_translate input.tif output.tif -of COG -co COMPRESS=LZW

This means that we need a geotiff (with CRS) and we only support LZW compression for now. This shouldn't be too hard to support other compression like JPEG (with YUV data) or deflate..