@gisatcz/deckgl-geolib 1.12.0-dev.1 → 1.12.0-dev.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +67 -64
- package/dist/cjs/index.js +3455 -13068
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/index.min.js +3 -4
- package/dist/cjs/index.min.js.map +1 -1
- package/dist/cjs/types/core/CogTiles.d.ts +134 -0
- package/dist/{esm/types/geoimage/geoimage.d.ts → cjs/types/core/GeoImage.d.ts} +7 -6
- package/dist/cjs/types/core/index.d.ts +2 -0
- package/dist/cjs/types/index.d.ts +2 -11
- package/dist/{esm/types/cogbitmaplayer → cjs/types/layers}/CogBitmapLayer.d.ts +3 -5
- package/dist/cjs/types/layers/index.d.ts +2 -0
- package/dist/esm/index.js +3452 -13068
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/index.min.js +3 -4
- package/dist/esm/index.min.js.map +1 -1
- package/dist/esm/types/core/CogTiles.d.ts +134 -0
- package/dist/{cjs/types/geoimage/geoimage.d.ts → esm/types/core/GeoImage.d.ts} +7 -6
- package/dist/esm/types/core/index.d.ts +2 -0
- package/dist/esm/types/index.d.ts +2 -11
- package/dist/{cjs/types/cogbitmaplayer → esm/types/layers}/CogBitmapLayer.d.ts +3 -5
- package/dist/esm/types/layers/index.d.ts +2 -0
- package/package.json +25 -4
- package/.eslintignore +0 -2
- package/.eslintrc.cjs +0 -3
- package/CHANGELOG.md +0 -166
- package/dist/cjs/types/cogtiles/cogtiles.d.ts +0 -29
- package/dist/esm/types/cogtiles/cogtiles.d.ts +0 -29
- package/rollup.config.mjs +0 -77
- package/src/cogbitmaplayer/CogBitmapLayer.ts +0 -326
- package/src/cogbitmaplayer/README.md +0 -113
- package/src/cogterrainlayer/CogTerrainLayer.ts +0 -445
- package/src/cogterrainlayer/README.md +0 -118
- package/src/cogtiles/README.md +0 -72
- package/src/cogtiles/cogtiles.ts +0 -316
- package/src/cogtiles/lzw.js +0 -256
- package/src/geoimage/README.md +0 -129
- package/src/geoimage/delatin/index.ts +0 -495
- package/src/geoimage/geoimage.ts +0 -597
- package/src/geoimage/helpers/skirt.ts +0 -171
- package/src/index.ts +0 -11
- package/src/utilities/tileurls.ts +0 -21
- package/tsconfig.json +0 -6
- /package/dist/cjs/types/{geoimage → core}/delatin/index.d.ts +0 -0
- /package/dist/cjs/types/{geoimage → core}/helpers/skirt.d.ts +0 -0
- /package/dist/cjs/types/{cogterrainlayer → layers}/CogTerrainLayer.d.ts +0 -0
- /package/dist/cjs/types/{utilities → utils}/tileurls.d.ts +0 -0
- /package/dist/esm/types/{geoimage → core}/delatin/index.d.ts +0 -0
- /package/dist/esm/types/{geoimage → core}/helpers/skirt.d.ts +0 -0
- /package/dist/esm/types/{cogterrainlayer → layers}/CogTerrainLayer.d.ts +0 -0
- /package/dist/esm/types/{utilities → utils}/tileurls.d.ts +0 -0
package/README.md
CHANGED
|
@@ -1,84 +1,69 @@
|
|
|
1
|
-
|
|
1
|
+
# @gisatcz/deckgl-geolib
|
|
2
|
+
|
|
3
|
+
<p style="text-align: right;">
|
|
2
4
|
<a href="https://www.npmjs.com/package/@gisatcz/deckgl-geolib">
|
|
3
5
|
<img src="https://img.shields.io/npm/v/@gisatcz/deckgl-geolib.svg?style=flat-square" alt="version" />
|
|
4
6
|
</a>
|
|
5
7
|
</p>
|
|
6
8
|
|
|
7
|
-
|
|
9
|
+
**A Deck.gl extension for rendering Cloud-Optimized GeoTIFF (COG) data.**
|
|
8
10
|
|
|
9
|
-
|
|
10
|
-
currently supporting Cloud-Optimized GeoTIFF (COG) files. This library offers an efficient way to display bitmap and
|
|
11
|
-
terrain data in applications with advanced customization options using [CogBitmapLayer](../geoimage/src/cogbitmaplayer/README.md)
|
|
12
|
-
and [CogTerrainLayer](../geoimage/src/cogterrainlayer/README.md). Another developed libraries [GeoImage](../geoimage/src/geoimage/README.md)
|
|
13
|
-
and [CogTiles](../geoimage/src/cogtiles/README.md) enhance rendering options.
|
|
11
|
+
This library allows you to efficiently visualize high-resolution bitmap and terrain data directly from COG sources. It includes the `CogBitmapLayer` for 2D imagery/heatmaps and the `CogTerrainLayer` for 3D terrain meshes.
|
|
14
12
|
|
|
15
|
-
|
|
13
|
+

|
|
16
14
|
|
|
17
|
-
##
|
|
15
|
+
## Features
|
|
18
16
|
|
|
19
|
-
- **COG Rendering**: Efficiently loads and displays
|
|
20
|
-
- **Bitmap and Terrain Layers**: Supports visualizing both
|
|
21
|
-
- **Customizable Rendering**: Allows custom color scales,
|
|
17
|
+
- **COG Rendering**: Efficiently loads and displays COG files directly without a backend server.
|
|
18
|
+
- **Bitmap and Terrain Layers**: Supports visualizing both raster and elevation data.
|
|
19
|
+
- **Customizable Rendering**: Allows custom color scales, multichannel support, and opacity control.
|
|
22
20
|
|
|
23
21
|
|
|
24
22
|
## Installation
|
|
25
23
|
|
|
26
|
-
To use the Geolib Visualizer library, you need to have deck.gl and its dependencies installed.
|
|
27
|
-
|
|
28
|
-
Install the Geolib Visualizer via npm or yarn:
|
|
24
|
+
To use the Geolib Visualizer library, you need to have deck.gl and its dependencies installed.
|
|
29
25
|
|
|
30
|
-
```
|
|
26
|
+
```bash
|
|
31
27
|
npm install @gisatcz/deckgl-geolib
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
or
|
|
35
|
-
```
|
|
28
|
+
# or
|
|
36
29
|
yarn add @gisatcz/deckgl-geolib
|
|
37
30
|
```
|
|
38
31
|
|
|
39
|
-
For more information, visit the [npm package page](https://www.npmjs.com/package/@gisatcz/deckgl-geolib).
|
|
40
|
-
You can visit the package page to explore further versions and additional information.
|
|
41
|
-
|
|
42
|
-
## COG Data Preparation
|
|
43
|
-
For seamless integration of Geolib Visualizer library, please make sure you have followed our workflow [Data Preparation Guide for converting GeoTIFFs to COG files](../dataPreparation.md).
|
|
44
|
-
|
|
45
|
-
|
|
32
|
+
For more information, visit the [npm package page](https://www.npmjs.com/package/@gisatcz/deckgl-geolib).
|
|
46
33
|
|
|
47
34
|
## Usage
|
|
48
35
|
|
|
49
|
-
Import package into project:
|
|
50
|
-
|
|
51
|
-
```typescript
|
|
52
|
-
import geolib from '@gisatcz/deckgl-geolib'
|
|
53
|
-
```
|
|
54
36
|
|
|
55
|
-
### 1.
|
|
37
|
+
### 1. CogBitmapLayer
|
|
56
38
|
|
|
57
|
-
|
|
58
|
-
The example below demonstrates its implementation, for more information and examples refer to the [CogBitmapLayer](../geoimage/src/cogbitmaplayer/README.md).
|
|
39
|
+
Used for displaying 2D rasters (satellite imagery, analysis results, heatmaps).
|
|
59
40
|
|
|
60
41
|
```typescript
|
|
61
|
-
|
|
42
|
+
import { CogBitmapLayer } from '@gisatcz/deckgl-geolib';
|
|
62
43
|
|
|
63
|
-
const cogLayer = new CogBitmapLayer(
|
|
44
|
+
const cogLayer = new CogBitmapLayer({
|
|
64
45
|
id: 'cog_bitmap_name',
|
|
65
46
|
rasterData: 'cog_bitmap_data_url.tif',
|
|
66
47
|
isTiled: true,
|
|
67
48
|
cogBitmapOptions: {
|
|
68
49
|
type: 'image'
|
|
69
50
|
}
|
|
70
|
-
);
|
|
51
|
+
});
|
|
71
52
|
```
|
|
72
|
-
### 2. COG Terrain Layer
|
|
73
53
|
|
|
74
|
-
|
|
75
|
-
|
|
54
|
+
Detailed Documentation:
|
|
55
|
+
* [API Reference & Examples](docs/layer-cogbitmap.md)
|
|
56
|
+
* [Visualization Options (GeoImage Core)](docs/architecture-geoimage.md)
|
|
57
|
+
|
|
58
|
+
### 2. CogTerrainLayer
|
|
59
|
+
|
|
60
|
+
Used for displaying 3D terrain from elevation data.
|
|
76
61
|
|
|
77
62
|
|
|
78
63
|
```typescript
|
|
79
|
-
|
|
64
|
+
import { CogTerrainLayer } from '@gisatcz/deckgl-geolib';
|
|
80
65
|
|
|
81
|
-
const cogLayer = new CogTerrainLayer(
|
|
66
|
+
const cogLayer = new CogTerrainLayer({
|
|
82
67
|
id: 'cog_terrain_name',
|
|
83
68
|
elevationData: 'cog_terrain_data_url.tif',
|
|
84
69
|
isTiled: true,
|
|
@@ -88,34 +73,52 @@ const cogLayer = new CogTerrainLayer(
|
|
|
88
73
|
terrainOptions: {
|
|
89
74
|
type: 'terrain',
|
|
90
75
|
}
|
|
91
|
-
);
|
|
76
|
+
});
|
|
92
77
|
```
|
|
93
78
|
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
initialViewState={INITIAL_VIEW_STATE}
|
|
98
|
-
controller={true}
|
|
99
|
-
layers={cogLayer} />
|
|
100
|
-
```
|
|
79
|
+
Detailed Documentation:
|
|
80
|
+
* [API Reference & Examples](docs/layer-cogterrain.md)
|
|
81
|
+
* [Terrain Processing Options (GeoImage Core)](docs/architecture-geoimage.md)
|
|
101
82
|
|
|
102
|
-
##
|
|
103
|
-
|
|
104
|
-
|
|
83
|
+
## Data Preparation
|
|
84
|
+
|
|
85
|
+
For this library to work efficiently, your COG must be Web-Optimized and projected in Web Mercator (EPSG:3857).
|
|
86
|
+
|
|
87
|
+
Quick Checklist:
|
|
88
|
+
1. **Projection:** Web Mercator EPSG:3857
|
|
89
|
+
2. **Tiling:** 256x256 tiles
|
|
90
|
+
3. **Compression:** DEFLATE is recommended
|
|
91
|
+
|
|
92
|
+
[Read the full Data Preparation Guide](docs/dataPreparation.md)
|
|
93
|
+
*(Includes standard commands for `rio-cogeo`)*
|
|
94
|
+
|
|
95
|
+
|
|
96
|
+
## Architecture & Development
|
|
97
|
+
|
|
98
|
+
This repository is a monorepo containing the core library and example applications.
|
|
99
|
+
|
|
100
|
+
* `geoimage/`: The core library source code.
|
|
101
|
+
* `example/`: A React application for testing the layers.
|
|
102
|
+
|
|
103
|
+
### Building Locally
|
|
104
|
+
|
|
105
|
+
```bash
|
|
106
|
+
# 1. Install dependencies
|
|
105
107
|
yarn install
|
|
106
|
-
```
|
|
107
|
-
Start an example
|
|
108
108
|
|
|
109
|
-
|
|
109
|
+
# 2. Build the library
|
|
110
|
+
yarn build
|
|
111
|
+
|
|
112
|
+
# 3. Run the example app
|
|
110
113
|
yarn start
|
|
111
114
|
```
|
|
112
|
-
The example is defaultly running at http://localhost:5173/
|
|
113
|
-
|
|
114
|
-
The bitmap and terrain example files are located here [example/src/examples](../example/src/examples)
|
|
115
115
|
|
|
116
|
-
|
|
116
|
+
### Technical Documentation
|
|
117
|
+
For developers contributing to the core logic:
|
|
118
|
+
* [GeoImage Internal Logic](docs/architecture-geoimage.md) – How the image processing and configuration work.
|
|
119
|
+
* [CogTiles Architecture](docs/architecture-cogtiles.md) – How the tiling grid is calculated.
|
|
117
120
|
|
|
118
|
-
[//]: # (Contributions and feedback are welcome! If you encounter any issues or have suggestions for improvements, please feel free to open an issue or submit a pull request.)
|
|
119
121
|
|
|
120
|
-
|
|
121
|
-
|
|
122
|
+
<p style="text-align: center;">
|
|
123
|
+
<sub>Maintained by <a href="https://gisat.cz">Gisat</a></sub>
|
|
124
|
+
</p>
|