12.0.1-next.4 • Published 18 days ago

@dlr-eoc/map-three v12.0.1-next.4

Weekly downloads
-
License
Apache-2.0
Repository
github
Last release
18 days ago

@dlr-eoc/map-three

This module exposes a component ukis-map-three analogous to ukis-map-ol.

Motivation and approach

There are a few objects that are very big, but still irregularly shaped. Because they are big, it makes sense to serve their image-material per WMTS instead of a single, humongous file. Because they are irregularly shaped, it makes sense to display them in 3d.

Here we use threejs to address those requirements. A threejs scene is being created with orbit-control circling around a singular Mesh. This mesh makes use of a custom shader, that uses a canvas of a map in EPSG:4326 as a texture. This way, any map in EPSG:4326 can be wrapped around any shape. The texture-canvas is being kept in sync with the map. As such, when new tiles are loaded on the map, they are immediately visible on the mesh.

Design

We have attempted to create a design as similar as possible to the existing ukis-map-ol. There is a component MapThreeComponent that accepts all relevant parameters as @Input. There is a service MapThreeService that handles the actual setup of a threejs-scene and all other interaction with the threejs-API. We also sync the scene with MapStateService so that all maps in the app show the same information.

Contrary to ukis-map-ol, however, no LayerService or controls are expected. Instead, the component expects an MapOlService as inputs. The reason for this difference is that this component does in fact depend on openlayers: the map that is wrapped around our mesh must have been generated somewhere.

What if I only want to show the 3d-scene?

Create a ukis-map-ol anyway, but hide it behind ukis-map-three. This way, openlayers can still handle all the WMTS loading logic and other complicated map-functionality, while this component continues to focus on 3d-specific problems.

TODOs

  • avoid those gray areas where no texture is present. Either:
    • make ol-map larger (but make that new padding invisible to the user),
    • or store a full map extent (in small resolution) in a framebuffer and fall back to it when no texture is available.
  • extend the shader to handle lighting
  • implement a raycaster to handle click-events on the mesh (also returning geographic coordinate of click)
  • handle multi-center objects like 67P/Churyumov–Gerasimenko
  • use brower-cache so gltf models don't need to be reloaded
12.0.1-next.4

18 days ago

12.0.1-next.3

18 days ago

12.0.1-next.2

2 months ago

12.0.1-next.1

2 months ago

12.0.1-next.0

4 months ago

12.0.0

5 months ago

12.0.0-alpha.1

10 months ago

12.0.0-alpha.0

10 months ago

12.0.0-alpha.2

9 months ago

11.1.0

12 months ago

11.0.0

1 year ago

10.0.0

2 years ago

10.1.0

2 years ago

11.0.0-alpha.1

1 year ago

10.0.0-next.0

2 years ago

11.0.0-alpha.0

1 year ago

10.0.0-next.1

2 years ago

9.0.0

2 years ago

8.1.0

2 years ago

8.0.1

2 years ago

8.0.0-next.3

2 years ago

8.0.0-next.4

2 years ago

8.0.0

2 years ago

8.0.0-next.2

3 years ago

8.0.0-next.1

3 years ago

8.0.0-next.0

3 years ago

7.3.2-next.3

3 years ago

7.3.2-next.2

3 years ago

7.3.2-next.1

3 years ago

7.3.1

3 years ago

7.3.0-next.3

3 years ago

7.3.0-next.2

3 years ago

7.3.0-next.1

3 years ago

7.3.0-next.0

3 years ago

7.2.0

4 years ago