README.md 1.67 KB
Newer Older
Athanasios's avatar
Athanasios committed
1
# Node 3D Portrayal Service
Athanasios's avatar
Athanasios committed
2
3

![](figures/home.jpg)
Athanasios's avatar
Athanasios committed
4

Athanasios's avatar
Athanasios committed
5
This is a 3D Portrayal Service implementation that is compatible with [3D Tiles](https://github.com/CesiumGS/3d-tiles) and [i3s](https://github.com/Esri/i3s-spec) specifications (returns metadata in the response).
Athanasios's avatar
Athanasios committed
6
7
8
9
10
11
12
13
14
15
16
17


## Installing

The service is implemented using [Node js](https://nodejs.org/en/). Install the dependencies with the `npm install` command. For the moment there is no bundler. Place the contents of the repository on your server with Node.js installed and run the "start" script with npm.

`npm run start`

If your server has a process manager installed, then configure accordingly.

## Usage

Athanasios's avatar
Athanasios committed
18
You can change the port in `config.js`, default port is 9000.
Athanasios's avatar
Athanasios committed
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
You access the service with the `/service/v1` endpoint and then provide additional query parameters:
* getCapabilities: `{host}:{port}/service/v1?`
* getCapabilities query parameters:

`service=3DPS`

`&acceptversions=1.0`

`&request=getCapabilities`

The getCapabilities request generates dynamically a response based on the `assets/assets.json` file.

* getScene: `{host}:{port}/service/v1?`
* getScene query parameters:

`service=3DPS`

`&acceptversions=1.0`

`&request=getScene`

Joe TS Dell's avatar
Joe TS Dell committed
40
`&layers=Buildings_Hamburg`
Athanasios's avatar
Athanasios committed
41

Joe TS Dell's avatar
Joe TS Dell committed
42
43
44
`&boundingbox=lon_1,lat_1,lon_2,lat_2` (optional)

`&crs=EPSG:4326`
Athanasios's avatar
Athanasios committed
45

Athanasios's avatar
Athanasios committed
46
47
48
49
When the query parameters are not valid an xml exception is returned.

## Examples

Athanasios's avatar
Athanasios committed
50
* [localhost getCapabilities](http://localhost:9000/service/v1?service=3DPS&acceptversions=1.0&request=getCapabilities)
Joe TS Dell's avatar
Joe TS Dell committed
51
* [localhost getScene](http://localhost:9000/service/v1?service=3DPS&acceptversions=1.0&request=getScene&layers=Niedernhall&boundingbox=9.6158087151,49.2935455509,9.6202933686,49.2963390299&crs=EPSG:4326)