Skip to content

Commit

Permalink
docs(tile-converter): Add documentation for SLPK Extractor (#2567)
Browse files Browse the repository at this point in the history
  • Loading branch information
dariaterekhova-actionengine authored Aug 4, 2023
1 parent 6e4979c commit 86a1ff4
Show file tree
Hide file tree
Showing 2 changed files with 54 additions and 0 deletions.
1 change: 1 addition & 0 deletions docs/docs-sidebar.json
Original file line number Diff line number Diff line change
Expand Up @@ -372,6 +372,7 @@
"items": [
"modules/tile-converter/cli-reference/tile-converter",
"modules/tile-converter/cli-reference/i3s-server",
"modules/tile-converter/cli-reference/slpk-extractor",
"modules/tile-converter/cli-reference/supported-features"
]
}
Expand Down
53 changes: 53 additions & 0 deletions docs/modules/tile-converter/cli-reference/slpk-extractor.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
# SLPK extractor

<p class="badges">
<img src="https://img.shields.io/badge/From-v4.0-blue.svg?style=flat-square" alt="From-v4.0" />
<a href="https://badge.fury.io/js/%40loaders.gl%2Ftile-converter">
<img src="https://badge.fury.io/js/%40loaders.gl%2Ftile-converter.svg" alt="npm version" height="18" />
</a>
</p>

SLPK extractor is utility that helps to extract slpk to a dataset that can be served via i3s-server

## Installation

The slpk-extractor is published as a part of `@loaders.gl/tile-converter`

Create a new folder:

```bash
mkdir tmp
cd tmp
```

Install `@loaders.gl/tile-converter` package:

```bash
npm i @loaders.gl/tile-converter
```

## Extraction

Extract .slpk to the `./data` folder:

```bash
npx slpk-extractor --tileset="./path/to/the/file.slpk" --output="./data//SceneServer/layers/0"
```
Then you can start serving dataset

### Start HTTP server
```bash
PORT=8080 HTTPS_PORT=4443 I3sLayerPath="./data" DEBUG=i3s-server:* npx i3s-server
```

#### The layer should be available on URLs
- `http://localhost:8080/SceneServer/layers/0`
- `https://localhost:4443/SceneServer/layers/0`

#### Open in ArcGIS

`https://www.arcgis.com/home/webscene/viewer.html?url=http://localhost:8080//SceneServer`

#### Open in I3S Explorer

`https://i3s.loaders.gl/viewer?tileset=http://localhost:8080/SceneServer/layers/0`

0 comments on commit 86a1ff4

Please sign in to comment.